The fix for schemeless and hostless URLs (rev. 1.27) broke the schemeless

proxy specification, which seems to be valid according to the man page.

Change the logic to consider "hostname:port" a hostname and port instead
of a file URL.

Approved by:	des
This commit is contained in:
se 2001-07-28 21:28:14 +00:00
parent 0e8c179d31
commit 826e0cf822

View File

@ -319,7 +319,8 @@ fetchParseURL(const char *URL)
p = URL;
}
if (!*URL || *URL == '/' || *URL == '.' ||
(u->scheme[0] == '\0' && strchr(URL, '/') == NULL))
(u->scheme[0] == '\0' &&
strchr(URL, '/') == NULL && strchr(URL, ':') == NULL))
goto nohost;
p = strpbrk(URL, "/@");