From 348dcd47e89434aa3673e61b629a2652d61f47ea Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Thu, 21 Jan 2021 15:41:57 +0100 Subject: fixup for sync resolver --- lib/hostip.c | 8 ++++---- lib/hostip6.c | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/hostip.c b/lib/hostip.c index a71a8db06..9ca9bdbe7 100644 --- a/lib/hostip.c +++ b/lib/hostip.c @@ -692,7 +692,7 @@ enum resolve_t Curl_resolv_timeout(struct Curl_easy *data, if(!timeout) /* USE_ALARM_TIMEOUT defined, but no timeout actually requested */ - return Curl_resolv(conn, hostname, port, TRUE, entry); + return Curl_resolv(data, hostname, port, TRUE, entry); if(timeout < 1000) { /* The alarm() function only provides integer second resolution, so if @@ -745,7 +745,7 @@ enum resolve_t Curl_resolv_timeout(struct Curl_easy *data, #else #ifndef CURLRES_ASYNCH if(timeoutms) - infof(conn->data, "timeout on name lookup is not supported\n"); + infof(data, "timeout on name lookup is not supported\n"); #else (void)timeoutms; /* timeoutms not used with an async resolver */ #endif @@ -781,7 +781,7 @@ clean_up: if(prev_alarm) { /* there was an alarm() set before us, now put it back */ timediff_t elapsed_secs = Curl_timediff(Curl_now(), - conn->created) / 1000; + data->conn->created) / 1000; /* the alarm period is counted in even number of seconds */ unsigned long alarm_set = (unsigned long)(prev_alarm - elapsed_secs); @@ -1087,7 +1087,7 @@ int Curl_resolv_getsock(struct Curl_easy *data, return GETSOCK_BLANK; return Curl_resolver_getsock(data, socks); #else - (void)conn; + (void)data; (void)socks; return GETSOCK_BLANK; #endif diff --git a/lib/hostip6.c b/lib/hostip6.c index 16bf3b03d..53b3c6722 100644 --- a/lib/hostip6.c +++ b/lib/hostip6.c @@ -163,7 +163,7 @@ struct Curl_addrinfo *Curl_getaddrinfo(struct Curl_easy *data, memset(&hints, 0, sizeof(hints)); hints.ai_family = pf; - hints.ai_socktype = (conn->transport == TRNSPRT_TCP) ? + hints.ai_socktype = (data->conn->transport == TRNSPRT_TCP) ? SOCK_STREAM : SOCK_DGRAM; #ifndef USE_RESOLVE_ON_IPS -- cgit v1.2.1