From: Felipe Pena Date: Thu, 8 Jan 2009 17:19:50 +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.3.0beta1~231 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=b5182d7affb52a88410892b6f4d477c6341b9c13;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 8397b8ae8a..63f24b97d4 100644 --- a/ext/standard/dns.c +++ b/ext/standard/dns.c @@ -469,7 +469,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: