The flags passed in to _ftp_get_proxy may be null

Approved by:	des, markm (mentor)(implicit)
This commit is contained in:
Mike Makonnen 2003-03-19 21:39:00 +00:00
parent 35522a0aa1
commit 4418f9df30
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=112420

View File

@ -894,7 +894,7 @@ _ftp_get_proxy(const char *flags)
struct url *purl;
char *p;
if (strchr(flags, 'd') != NULL)
if (flags != NULL && strchr(flags, 'd') != NULL)
return (NULL);
if (((p = getenv("FTP_PROXY")) || (p = getenv("ftp_proxy")) ||
(p = getenv("HTTP_PROXY")) || (p = getenv("http_proxy"))) &&