From: Michael Wallner Date: Tue, 24 Apr 2012 18:35:49 +0000 (+0200) Subject: fix bug #61443 X-Git-Tag: php-5.4.4RC1~88 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=7c93a16477d7e4d6e0386d0613558360f036d57b;p=php fix bug #61443 Since upgrade to PHP 5.4, we can't change zlib.output_compression on the fly the check for PHP_OUTPUT_WRITTEN was over-zealous --- diff --git a/ext/zlib/tests/bug61443.phpt b/ext/zlib/tests/bug61443.phpt new file mode 100644 index 0000000000..ea2fa68c89 --- /dev/null +++ b/ext/zlib/tests/bug61443.phpt @@ -0,0 +1,15 @@ +--TEST-- +bug #61443 +--SKIPIF-- + +--FILE-- + +DONE +--EXPECTF-- +end +DONE diff --git a/ext/zlib/zlib.c b/ext/zlib/zlib.c index 545979dc9c..f157821bf5 100644 --- a/ext/zlib/zlib.c +++ b/ext/zlib/zlib.c @@ -884,9 +884,6 @@ static PHP_INI_MH(OnUpdate_zlib_output_compression) if (status & PHP_OUTPUT_SENT) { php_error_docref("ref.outcontrol" TSRMLS_CC, E_WARNING, "Cannot change zlib.output_compression - headers already sent"); return FAILURE; - } else if ((status & PHP_OUTPUT_WRITTEN) && int_value) { - php_error_docref("ref.outcontrol" TSRMLS_CC, E_WARNING, "Cannot enable zlib.output_compression - there has already been output"); - return FAILURE; } }