diff options
| author | Daniel Stenberg <daniel@haxx.se> | 2008-11-01 23:49:54 +0000 | 
|---|---|---|
| committer | Daniel Stenberg <daniel@haxx.se> | 2008-11-01 23:49:54 +0000 | 
| commit | 85ffd33f087640bf43fe974cf4c70ad2c3929312 (patch) | |
| tree | ff034d904b100bd00042184754bbae45ff932ca0 /lib | |
| parent | c1b8e93083e22c263232d91d00c7d537dbf4a85b (diff) | |
Daniel Johnson reported and fixed ipv4 name resolves when libcurl is built
with ipv6-enabled c-ares
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/hostares.c | 5 | 
1 files changed, 4 insertions, 1 deletions
| diff --git a/lib/hostares.c b/lib/hostares.c index d7dceaa1d..f17cdf5ec 100644 --- a/lib/hostares.c +++ b/lib/hostares.c @@ -399,9 +399,12 @@ Curl_addrinfo *Curl_getaddrinfo(struct connectdata *conn,    switch(data->set.ip_version) {    case CURL_IPRESOLVE_V4: +  default: /* By default we try ipv4, as PF_UNSPEC isn't supported by c-ares. +              This is a bit disturbing since users may very well assume that +              both kinds of addresses are asked for, but the problem is really +              in c-ares' end here. */      family = PF_INET;      break; -  default: /* by default we try ipv6, as PF_UNSPEC isn't supported by (c-)ares */    case CURL_IPRESOLVE_V6:      family = PF_INET6;      break; | 
