Fix regression in HTTP authentication

* src/http.c (initialize_request): Fix wrong params to search_netrc()

Regression introduced in commit 29850e77
Reported-by: Axel Reinhold <axel@freakout.de>
This commit is contained in:
Tim Rühsen 2015-11-23 17:50:59 +01:00
parent 218d81f6e5
commit 4e37fb6191
1 changed files with 1 additions and 1 deletions

View File

@ -1872,7 +1872,7 @@ initialize_request (struct url *u, struct http_stat *hs, int *dt, struct url *pr
/* Find the username and password for authentication. */
*user = u->user;
*passwd = u->passwd;
search_netrc (u->host, (const char **)&user, (const char **)&passwd, 0);
search_netrc (u->host, (const char **)user, (const char **)passwd, 0);
*user = *user ? *user : (opt.http_user ? opt.http_user : opt.user);
*passwd = *passwd ? *passwd : (opt.http_passwd ? opt.http_passwd : opt.passwd);