diff options
author | Arnaud Le Blanc <lbarnaud@php.net> | 2009-05-28 10:15:14 +0000 |
---|---|---|
committer | Arnaud Le Blanc <lbarnaud@php.net> | 2009-05-28 10:15:14 +0000 |
commit | 6a9aa30d858eb61316410b7fb87662f3288869f0 (patch) | |
tree | 5abff4294ac71718dae546ea9929cab93c9a258c /ext/zlib | |
parent | 04d8609e9fdf3087f98211e3cc5e4878a54a276c (diff) | |
download | php-git-6a9aa30d858eb61316410b7fb87662f3288869f0.tar.gz |
MFB52: Fix "request_startup() for zlib module failed" when client does not
accepts compression and zlib.output_compression is On
# (not in HEAD)
Diffstat (limited to 'ext/zlib')
-rw-r--r-- | ext/zlib/tests/008.phpt | 11 | ||||
-rw-r--r-- | ext/zlib/zlib.c | 4 |
2 files changed, 14 insertions, 1 deletions
diff --git a/ext/zlib/tests/008.phpt b/ext/zlib/tests/008.phpt new file mode 100644 index 0000000000..4102e0c52d --- /dev/null +++ b/ext/zlib/tests/008.phpt @@ -0,0 +1,11 @@ +--TEST-- +zlib.output_compression=1 with client not accepting compression +--SKIPIF-- +<?php if (!extension_loaded('zlib')) die('skip'); ?> +--INI-- +zlib.output_compression=1 +display_startup_errors=1 +--FILE-- +===DONE=== +--EXPECT-- +===DONE=== diff --git a/ext/zlib/zlib.c b/ext/zlib/zlib.c index 4493db4cd9..e70ec7875b 100644 --- a/ext/zlib/zlib.c +++ b/ext/zlib/zlib.c @@ -319,7 +319,9 @@ static PHP_RINIT_FUNCTION(zlib) ZLIBG(ob_gzhandler_status) = 0; ZLIBG(compression_coding) = 0; - return php_zlib_output_compression_start(TSRMLS_C); + php_zlib_output_compression_start(TSRMLS_C); + + return SUCCESS; } /* }}} */ |