* src/http.c (initialize_request): Fix check for user

Reported-by: Coverity
This commit is contained in:
Tim Rühsen 2016-09-08 12:48:29 +02:00
parent 22aed3ed4b
commit b7b67e23cd

View File

@ -1885,7 +1885,7 @@ initialize_request (struct url *u, struct http_stat *hs, int *dt, struct url *pr
/* We only do "site-wide" authentication with "global" user/password
* values unless --auth-no-challange has been requested; URL user/password
* info overrides. */
if (user && *passwd && (!u->user || opt.auth_without_challenge))
if (*user && *passwd && (!u->user || opt.auth_without_challenge))
{
/* If this is a host for which we've already received a Basic
* challenge, we'll go ahead and send Basic authentication creds. */