From 2b6bb9f588aa791a385c8a5075ab5e207f9a739d Mon Sep 17 00:00:00 2001 From: Rod Vagg Date: Wed, 15 May 2013 21:25:11 +0200 Subject: [PATCH] deps: c-ares float, win ipv6 bad fec0 prefix Was 72c5458aee: PR-URL: https://github.com/nodejs/node/pull/5090 Reviewed-By: Fedor Indutny Reimplemented for c-ares 1.13.0 PR-URL: https://github.com/nodejs/node/pull/15378 Reviewed-By: James M Snell Reviewed-By: Ruben Bridgewater PR-URL: https://github.com/nodejs/node/pull/19939 Reviewed-By: Ruben Bridgewater Reviewed-By: Colin Ihrig Reviewed-By: James M Snell Reviewed-By: Ben Noordhuis --- deps/cares/src/ares_init.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/deps/cares/src/ares_init.c b/deps/cares/src/ares_init.c index 4cc2c76dbda5ab..90cfcabdd33a9e 100644 --- a/deps/cares/src/ares_init.c +++ b/deps/cares/src/ares_init.c @@ -1272,6 +1272,11 @@ static int get_DNS_AdaptersAddresses(char **outptr) } else if (namesrvr.sa->sa_family == AF_INET6) { + /* Windows apparently always reports some IPv6 DNS servers that + * prefixed with fec0:0:0:ffff. These ususally do not point to + * working DNS servers, so we ignore them. */ + if (strncmp(addresses[addressesIndex].text, "fec0:0:0:ffff:", 14) == 0) + continue; if (memcmp(&namesrvr.sa6->sin6_addr, &ares_in6addr_any, sizeof(namesrvr.sa6->sin6_addr)) == 0) continue;