make it build without ares support

make sure it set async false even when using ipv6 (made test case 20 fail
before)
This commit is contained in:
Daniel Stenberg 2003-08-06 15:26:02 +00:00
parent 665a7a3848
commit 62b65a5f20
1 changed files with 23 additions and 1 deletions

View File

@ -565,6 +565,27 @@ CURLcode Curl_wait_for_resolv(struct connectdata *conn,
*entry=NULL;
return CURLE_COULDNT_RESOLVE_HOST;
}
CURLcode Curl_multi_ares_fdset(struct connectdata *conn,
fd_set *read_fd_set,
fd_set *write_fd_set,
int *max_fdp)
{
(void)conn;
(void)read_fd_set;
(void)write_fd_set;
(void)max_fdp;
return CURLE_OK;
}
CURLcode Curl_is_resolved(struct connectdata *conn, bool *done)
{
(void)conn;
*done = TRUE;
return CURLE_OK;
}
#endif
#if defined(ENABLE_IPV6) && !defined(USE_ARES)
@ -623,6 +644,8 @@ static Curl_addrinfo *my_getaddrinfo(struct connectdata *conn,
int s, pf = PF_UNSPEC;
struct SessionHandle *data = conn->data;
*waitp=0; /* don't wait, we have the response now */
/* see if we have an IPv6 stack */
s = socket(PF_INET6, SOCK_DGRAM, 0);
if (s < 0)
@ -646,7 +669,6 @@ static Curl_addrinfo *my_getaddrinfo(struct connectdata *conn,
infof(data, "getaddrinfo(3) failed for %s:%d\n", hostname, port);
return NULL;
}
*waitp=0; /* don't wait, we have the response now */
return res;
}