mirror of
https://github.com/moparisthebest/curl
synced 2024-12-22 08:08:50 -05:00
better bailing-out cleanup if a malloc fails in the DNS cache
This commit is contained in:
parent
9010bd3831
commit
017a78d0c5
@ -344,6 +344,11 @@ int Curl_resolv(struct connectdata *conn,
|
||||
|
||||
if(data->share)
|
||||
Curl_share_unlock(data, CURL_LOCK_DATA_DNS);
|
||||
|
||||
if(!dns) {
|
||||
/* returned failure, bail out nicely */
|
||||
Curl_freeaddrinfo(addr);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user