Lines Matching refs:url

268 url_decode(char *url)  in url_decode()  argument
272 if (EMPTYSTRING(url)) in url_decode()
274 p = q = (unsigned char *)url; in url_decode()
322 parse_url(const char *url, const char *desc, url_t *utype, in parse_url() argument
330 if (url == NULL || desc == NULL || utype == NULL || uuser == NULL in parse_url()
334 DPRINTF("parse_url: %s `%s'\n", desc, url); in parse_url()
336 origurl = url; in parse_url()
342 if (STRNEQUAL(url, HTTP_URL)) { in parse_url()
343 url += sizeof(HTTP_URL) - 1; in parse_url()
347 } else if (STRNEQUAL(url, FTP_URL)) { in parse_url()
348 url += sizeof(FTP_URL) - 1; in parse_url()
352 } else if (STRNEQUAL(url, FILE_URL)) { in parse_url()
353 url += sizeof(FILE_URL) - 1; in parse_url()
356 warnx("Invalid %s `%s'", desc, url); in parse_url()
368 if (*url == '\0') in parse_url()
372 ep = strchr(url, '/'); in parse_url()
374 thost = ftp_strdup(url); in parse_url()
376 len = ep - url; in parse_url()
378 (void)strlcpy(thost, url, len + 1); in parse_url()
478 fetch_url(const char *url, const char *proxyenv, char *proxyauth, char *wwwauth) in fetch_url() argument
513 DPRINTF("fetch_url: `%s' proxyenv `%s'\n", url, STRorNULL(proxyenv)); in fetch_url()
525 if (parse_url(url, "URL", &urltype, &uuser, &pass, &host, &port, in fetch_url()
531 warnx("No support for non local file URL `%s'", url); in fetch_url()
537 rval = fetch_ftp(url); in fetch_url()
541 warnx("Invalid URL (no file after host) `%s'", url); in fetch_url()
561 rval = fetch_ftp(url); in fetch_url()
565 "output file) `%s'", url); in fetch_url()
652 rval = fetch_ftp(url); in fetch_url()
696 path = ftp_strdup(url); in fetch_url()
762 fprintf(ttyout, "Requesting %s\n", url); in fetch_url()
1034 rval = fetch_url(url, location, in fetch_url()
1082 rval = fetch_url(url, proxyenv, in fetch_url()
1133 url, savefile); in fetch_url()
1370 fetch_ftp(const char *url) in fetch_ftp() argument
1382 DPRINTF("fetch_ftp: `%s'\n", url); in fetch_ftp()
1388 if (STRNEQUAL(url, FTP_URL)) { in fetch_ftp()
1389 if ((parse_url(url, "URL", &urltype, &uuser, &pass, in fetch_ftp()
1393 warnx("Invalid URL `%s'", url); in fetch_ftp()
1413 url); in fetch_ftp()
1420 host = ftp_strdup(url); in fetch_ftp()
1710 go_fetch(const char *url) in go_fetch() argument
1718 if (STRNEQUAL(url, ABOUT_URL)) { in go_fetch()
1719 url += sizeof(ABOUT_URL) -1; in go_fetch()
1720 if (strcasecmp(url, "ftp") == 0 || in go_fetch()
1721 strcasecmp(url, "tnftp") == 0) { in go_fetch()
1725 } else if (strcasecmp(url, "lukem") == 0) { in go_fetch()
1729 } else if (strcasecmp(url, "netbsd") == 0) { in go_fetch()
1733 } else if (strcasecmp(url, "version") == 0) { in go_fetch()
1743 fprintf(ttyout, "`%s' is an interesting topic.\n", url); in go_fetch()
1753 if (STRNEQUAL(url, HTTP_URL) || STRNEQUAL(url, FILE_URL)) in go_fetch()
1754 return (fetch_url(url, NULL, NULL, NULL)); in go_fetch()
1762 if (!EMPTYSTRING(proxyenv) && STRNEQUAL(url, FTP_URL)) in go_fetch()
1763 return (fetch_url(url, NULL, NULL, NULL)); in go_fetch()
1765 return (fetch_ftp(url)); in go_fetch()