Check the FTP_LOGIN environment variable before falling back on

FTP_ANONYMOUS_USER.
This commit is contained in:
Dag-Erling Smørgrav 2000-12-22 18:01:40 +00:00
parent 3b93c7437b
commit e72f0de24e

View File

@ -761,6 +761,8 @@ _ftp_connect(struct url *url, struct url *purl, char *flags)
/* send user name and password */
user = url->user;
if (!user || !*user)
user = getenv("FTP_LOGIN");
if (!user || !*user)
user = FTP_ANONYMOUS_USER;
if (purl && url->port == _fetch_default_port(url->scheme))