From a0c8d5d80aa62d956bf1513de7dad391ff2f0af9 Mon Sep 17 00:00:00 2001 From: Antony Dovgal Date: Tue, 25 Oct 2005 08:19:33 +0000 Subject: [PATCH] MFH: fix problem with garbage appearing in hostnames --- ext/standard/dns.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ext/standard/dns.c b/ext/standard/dns.c index e139910e17..ffe8d0b702 100644 --- a/ext/standard/dns.c +++ b/ext/standard/dns.c @@ -379,7 +379,7 @@ static void _php_dns_free_res(struct __res_state res) { /* {{{ */ /* {{{ php_parserr */ static u_char *php_parserr(u_char *cp, querybuf *answer, int type_to_fetch, int store, zval **subarray) { - u_short type, dlen; + u_short type, class, dlen; u_long ttl; long n, i; u_short s; @@ -396,6 +396,7 @@ static u_char *php_parserr(u_char *cp, querybuf *answer, int type_to_fetch, int cp += n; GETSHORT(type, cp); + GETSHORT(class, cp); GETLONG(ttl, cp); GETSHORT(dlen, cp); if (type_to_fetch != T_ANY && type != type_to_fetch) { -- 2.50.1