1
0
mirror of https://github.com/moparisthebest/curl synced 2024-08-13 17:03:50 -04:00

asyn-thread: Set errno to the proper value ENOMEM in OOM situation

This used to be set in some configurations to EAI_MEMORY which is not a
valid value for errno and caused Curl_strerror to fail an assertion.
This commit is contained in:
Dan Fandrich 2017-08-28 23:41:04 +02:00
parent a330bab353
commit 11a8778e0b

View File

@ -380,7 +380,7 @@ static bool init_resolve_thread(struct connectdata *conn,
const struct addrinfo *hints)
{
struct thread_data *td = calloc(1, sizeof(struct thread_data));
int err = RESOLVER_ENOMEM;
int err = ENOMEM;
conn->async.os_specific = (void *)td;
if(!td)