From: Amos Jeffries Date: Sun, 23 Sep 2012 06:56:36 +0000 (-0600) Subject: MacOS: fix AddrInfo default flags X-Git-Tag: SQUID_3_1_21~3 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=06270e43b1a39c18077051adf1b0bacce6e342c5;p=thirdparty%2Fsquid.git MacOS: fix AddrInfo default flags --- diff --git a/src/ip/IpAddress.cc b/src/ip/IpAddress.cc index 434040eb67..5a1c68d39a 100644 --- a/src/ip/IpAddress.cc +++ b/src/ip/IpAddress.cc @@ -592,7 +592,12 @@ void IpAddress::GetAddrInfo(struct addrinfo *&dst, int force) const memset(dst, 0, sizeof(struct addrinfo)); // set defaults + // Mac OS X does not emit a flag indicating the output is numeric (IP address) +#if _SQUID_APPLE_ + dst->ai_flags = 0; +#else dst->ai_flags = AI_NUMERICHOST; +#endif if (dst->ai_socktype == 0) dst->ai_socktype = SOCK_STREAM;