diff --git a/net_util.c b/net_util.c index 9fd08f7..6589388 100644 --- a/net_util.c +++ b/net_util.c @@ -78,8 +78,10 @@ static char *dns_resolve_filter(const char *host, int32_t family, uint8_t max_ad // Copy address name into return string err = getnameinfo(address->ai_addr, (socklen_t)address->ai_addrlen, ai_string + ai_string_len, (uint32_t)(max_ai_string - ai_string_len), NULL, 0, NI_NUMERICHOST); - if (err != 0) - continue; + if (err != 0) { + printf("getnameinfo fail\n"); + goto dns_resolve_error; + } max_addrs--;