diff options
author | Daniel Stenberg <daniel@haxx.se> | 2007-07-22 10:17:52 +0000 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2007-07-22 10:17:52 +0000 |
commit | 9af807a5ce199adfb7372abd2a490d4af1179725 (patch) | |
tree | 849c2bc10bc0002583b44f5dcb0a88e0aae628ae /lib | |
parent | 4bbcc47f3f3a81ada6e7d620400c1388d6161e88 (diff) |
HTTP Digest auth fix on a re-used connection
Diffstat (limited to 'lib')
-rw-r--r-- | lib/http_digest.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/http_digest.c b/lib/http_digest.c index 604655f04..7338ce72a 100644 --- a/lib/http_digest.c +++ b/lib/http_digest.c @@ -266,6 +266,11 @@ CURLcode Curl_output_digest(struct connectdata *conn, authp = &data->state.authhost; } + if (*allocuserpwd) { + Curl_safefree(*allocuserpwd); + *allocuserpwd = NULL; + } + /* not set means empty */ if(!userp) userp=(char *)""; @@ -388,8 +393,6 @@ CURLcode Curl_output_digest(struct connectdata *conn, nonce="1053604145", uri="/64", response="c55f7f30d83d774a3d2dcacf725abaca" */ - Curl_safefree(*allocuserpwd); - if (d->qop) { *allocuserpwd = aprintf( "%sAuthorization: Digest " |