5 Dec
2008
5 Dec
'08
1:23 a.m.
Jeremy wrote:
On Thu, Dec 04, 2008 at 05:59:21PM +0000, corvid wrote:
+/* + * Return the host that contains a URL, or NULL if there is no such host. + */ +static AuthHost *Host_from_url(const DilloUrl *url) +{ + AuthHost *host; + int i; + + for (i = 0; (host = dList_nth_data(auth_hosts, i)); i++) + if (((strcmp(URL_SCHEME(url), host->scheme) == 0) && + (strcmp(URL_AUTHORITY(url), host->authority) == 0))) + return host; + + return NULL; +}
dStrcasecmp
When comparing the scheme, the authority, or both?
I think both. *pokes through rfc2396 for a bit* "When a scheme uses elements of the common syntax, it will also use the common syntax equivalence rules, namely that the scheme and hostname are case insensitive..."