version 1.182, 2019/12/08 23:43:53 |
version 1.183, 2019/12/09 00:45:34 |
|
|
#ifndef SMALL |
#ifndef SMALL |
scheme = FILE_URL; |
scheme = FILE_URL; |
#endif /* !SMALL */ |
#endif /* !SMALL */ |
#ifndef NOSSL |
|
} else if (strncasecmp(newline, HTTPS_URL, sizeof(HTTPS_URL) - 1) == 0) { |
} else if (strncasecmp(newline, HTTPS_URL, sizeof(HTTPS_URL) - 1) == 0) { |
|
#ifndef NOSSL |
host = newline + sizeof(HTTPS_URL) - 1; |
host = newline + sizeof(HTTPS_URL) - 1; |
ishttpsurl = 1; |
ishttpsurl = 1; |
|
#else |
|
errx(1, "%s: No HTTPS support", newline); |
|
#endif /* !NOSSL */ |
#ifndef SMALL |
#ifndef SMALL |
scheme = HTTPS_URL; |
scheme = HTTPS_URL; |
#endif /* !SMALL */ |
#endif /* !SMALL */ |
#endif /* !NOSSL */ |
|
} else |
} else |
errx(1, "url_get: Invalid URL '%s'", newline); |
errx(1, "url_get: Invalid URL '%s'", newline); |
|
|
|
|
* Try HTTP URL-style arguments first. |
* Try HTTP URL-style arguments first. |
*/ |
*/ |
if (strncasecmp(url, HTTP_URL, sizeof(HTTP_URL) - 1) == 0 || |
if (strncasecmp(url, HTTP_URL, sizeof(HTTP_URL) - 1) == 0 || |
#ifndef NOSSL |
|
/* even if we compiled without SSL, url_get will check */ |
|
strncasecmp(url, HTTPS_URL, sizeof(HTTPS_URL) -1) == 0 || |
strncasecmp(url, HTTPS_URL, sizeof(HTTPS_URL) -1) == 0 || |
#endif /* !NOSSL */ |
|
strncasecmp(url, FILE_URL, sizeof(FILE_URL) - 1) == 0) { |
strncasecmp(url, FILE_URL, sizeof(FILE_URL) - 1) == 0) { |
redirect_loop = 0; |
redirect_loop = 0; |
retried = 0; |
retried = 0; |