From b64791c7e45b09615ea5528e104d059a85b745e6 Mon Sep 17 00:00:00 2001 From: Ben Noordhuis Date: Tue, 16 Nov 2010 21:38:13 +0100 Subject: [PATCH] Fix c-ares bug: reply to a CNAME query doesn't contain addresses, causing ares_parse_a_reply() to bail out with ARES_ENODATA. --- deps/c-ares/ares_parse_a_reply.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deps/c-ares/ares_parse_a_reply.c b/deps/c-ares/ares_parse_a_reply.c index 86112d75be..72fd060d74 100644 --- a/deps/c-ares/ares_parse_a_reply.c +++ b/deps/c-ares/ares_parse_a_reply.c @@ -201,7 +201,7 @@ int ares_parse_a_reply(const unsigned char *abuf, int alen, } } - if (status == ARES_SUCCESS && naddrs == 0) + if (status == ARES_SUCCESS && naddrs == 0 && naliases == 0) status = ARES_ENODATA; if (status == ARES_SUCCESS) {