projects
/
platform
/
upstream
/
curl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
14b77db
)
curl_multi_remove_handle: fix memory leak triggered with CURLOPT_RESOLVE
author
Yang Tse
<yangsita@gmail.com>
Tue, 25 Dec 2012 12:31:26 +0000
(13:31 +0100)
committer
Yang Tse
<yangsita@gmail.com>
Tue, 25 Dec 2012 12:34:45 +0000
(13:34 +0100)
lib/multi.c
patch
|
blob
|
history
diff --git
a/lib/multi.c
b/lib/multi.c
index
52eeb7f
..
6834e68
100644
(file)
--- a/
lib/multi.c
+++ b/
lib/multi.c
@@
-649,6
+649,10
@@
CURLMcode curl_multi_remove_handle(CURLM *multi_handle,
}
if(easy->easy_handle->dns.hostcachetype == HCACHE_MULTI) {
+ if(multi->num_easy == 1) {
+ Curl_hostcache_destroy(easy->easy_handle);
+ multi->hostcache = NULL;
+ }
/* clear out the usage of the shared DNS cache */
easy->easy_handle->dns.hostcache = NULL;
easy->easy_handle->dns.hostcachetype = HCACHE_NONE;