summaryrefslogtreecommitdiff
path: root/lib/url.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2011-01-27 14:37:25 +0100
committerDaniel Stenberg <daniel@haxx.se>2011-01-27 14:41:07 +0100
commitef19e30985fabbe6f5abecf623f371450488653c (patch)
tree62857b4ed6125c787a066a7b16fb00a071df8c58 /lib/url.c
parent2d356ba1683d47ebbd08e9d6e4bb4acbb8729fee (diff)
downloadcurl-ef19e30985fabbe6f5abecf623f371450488653c.tar.gz
ares: memory leak fix
The double name resolve trick used with c-ares could leave allocated memory in 'temp_ai' if the operation was aborted in the middle.
Diffstat (limited to 'lib/url.c')
-rw-r--r--lib/url.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/url.c b/lib/url.c
index cd89e1f89..c07554182 100644
--- a/lib/url.c
+++ b/lib/url.c
@@ -5241,6 +5241,8 @@ CURLcode Curl_done(struct connectdata **connp,
data->req.location = NULL;
}
+ Curl_async_cancel(conn);
+
if(conn->dns_entry) {
Curl_resolv_unlock(data, conn->dns_entry); /* done with this */
conn->dns_entry = NULL;