diff options
author | Steve Holme <steve_holme@hotmail.com> | 2014-11-07 00:03:11 +0000 |
---|---|---|
committer | Steve Holme <steve_holme@hotmail.com> | 2014-11-07 00:11:20 +0000 |
commit | dcad09e1254776a89ec412e9b04131733b434527 (patch) | |
tree | 58a36260197dfc88537561807cd2c4786184b172 | |
parent | 338b64137093f366aaeec40f4058a2b493e6c8f1 (diff) |
http_digest: Fixed some memory leaks introduced in commit 6f8d8131b1
Fixed a couple of memory leaks as a result of moving code that used to
populate allocuserpwd and relied on it's clean up.
-rw-r--r-- | lib/curl_sasl.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/curl_sasl.c b/lib/curl_sasl.c index 7d5a63d61..1edeb2017 100644 --- a/lib/curl_sasl.c +++ b/lib/curl_sasl.c @@ -1046,20 +1046,20 @@ CURLcode Curl_sasl_create_digest_http_message(struct SessionHandle *data, if(digest->opaque) { /* Append the opaque */ tmp = aprintf("%s, opaque=\"%s\"", response, digest->opaque); + free(response); if(!tmp) return CURLE_OUT_OF_MEMORY; - free(response); response = tmp; } if(digest->algorithm) { /* Append the algorithm */ tmp = aprintf("%s, algorithm=\"%s\"", response, digest->algorithm); + free(response); if(!tmp) return CURLE_OUT_OF_MEMORY; - free(response); response = tmp; } |