mirror of
https://github.com/curl/curl.git
synced 2026-08-02 03:10:29 +03:00
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.
This commit is contained in:
parent
2d356ba168
commit
ef19e30985
2 changed files with 14 additions and 7 deletions
|
|
@ -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;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue