summaryrefslogtreecommitdiff
path: root/lib/asyn-thread.c
diff options
context:
space:
mode:
authorDan Fandrich <dan@coneharvesters.com>2017-08-28 23:41:04 +0200
committerDan Fandrich <dan@coneharvesters.com>2017-08-28 23:55:55 +0200
commit11a8778e0b720a1683dabdfe7d2b21f6dcb138fd (patch)
treea71be13db126159eaa373c1940dc8564a49f9d73 /lib/asyn-thread.c
parenta330bab353fb1f987c61806c9bbc6a1fc2103d1e (diff)
downloadcurl-11a8778e0b720a1683dabdfe7d2b21f6dcb138fd.tar.gz
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.
Diffstat (limited to 'lib/asyn-thread.c')
-rw-r--r--lib/asyn-thread.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/asyn-thread.c b/lib/asyn-thread.c
index 8936b6033..fa47f554a 100644
--- a/lib/asyn-thread.c
+++ b/lib/asyn-thread.c
@@ -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)