From: Ilia Alshanetsky Date: Thu, 29 Aug 2002 15:44:00 +0000 (+0000) Subject: Fixed bug #18966 X-Git-Tag: RELEASE_0_91~180 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=337448322f8797ac7778bce9c3fd500d1987d9c4;p=php Fixed bug #18966 --- diff --git a/ext/standard/dns.c b/ext/standard/dns.c index 5d65f12554..8dff743cd6 100644 --- a/ext/standard/dns.c +++ b/ext/standard/dns.c @@ -128,7 +128,7 @@ static char *php_gethostbyaddr(char *ip) hp = gethostbyaddr((char *) &addr, sizeof(addr), AF_INET); #endif - if (!hp) { + if (!hp || hp->h_name == NULL || hp->h_name == '\0') { return estrdup(ip); }