From: Julien Pauli Date: Thu, 17 Nov 2016 10:33:36 +0000 (+0100) Subject: Improvement for bug73297 X-Git-Tag: php-7.1.0~3^2~17^2~1 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=0f9225f89311489e46d7d9c60f84536a122c523b;p=php Improvement for bug73297 --- diff --git a/ext/standard/http_fopen_wrapper.c b/ext/standard/http_fopen_wrapper.c index b751488fc9..b9ca25687e 100644 --- a/ext/standard/http_fopen_wrapper.c +++ b/ext/standard/http_fopen_wrapper.c @@ -708,7 +708,7 @@ finish: while ( !php_stream_eof(stream) && php_stream_get_line(stream, tmp_line, sizeof(tmp_line) - 1, &tmp_line_len) != NULL - && ( tmp_line_len < 6 || strncasecmp(tmp_line, "HTTP/1", 6) ) + && ( tmp_line_len < sizeof("HTTP/1") - 1 || strncasecmp(tmp_line, "HTTP/1", sizeof("HTTP/1") - 1) ) ); if (tmp_line_len > 9) {