From: Felipe Pena Date: Thu, 8 Jan 2009 17:20:21 +0000 (+0000) Subject: - MFH: Fixed bug #47035 (dns_get_record returns a garbage byte at the end of a TXT... X-Git-Tag: php-5.2.9RC1~144 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=6c3a5e8d05884a675a9247b45fa25d2cc316777d;p=php - MFH: Fixed bug #47035 (dns_get_record returns a garbage byte at the end of a TXT record) --- diff --git a/ext/standard/dns.c b/ext/standard/dns.c index 6fd0d7a5e5..1bef335cb6 100644 --- a/ext/standard/dns.c +++ b/ext/standard/dns.c @@ -487,7 +487,7 @@ static u_char *php_parserr(u_char *cp, querybuf *answer, int type_to_fetch, int tp[dlen] = '\0'; cp += dlen; - add_assoc_stringl(*subarray, "txt", tp, dlen, 0); + add_assoc_stringl(*subarray, "txt", tp, dlen - 1, 0); } break; case DNS_T_SOA: