diff options
author | Xinchen Hui <laruence@php.net> | 2012-07-21 02:58:16 +0800 |
---|---|---|
committer | Xinchen Hui <laruence@php.net> | 2012-07-21 02:58:16 +0800 |
commit | 64cbdc606cdfeab3972851d9050db70b1ef5eea7 (patch) | |
tree | a26b09967fd8536e095325b7cf91e9987f81f590 /ext/zlib | |
parent | b39c0749acbe47cdf4db3c89edc33f5e9e9961c4 (diff) | |
parent | a6f1533789b897d3b8930b437164e81e0a0f4c72 (diff) | |
download | php-git-64cbdc606cdfeab3972851d9050db70b1ef5eea7.tar.gz |
Merge branch 'PHP-5.4'
Diffstat (limited to 'ext/zlib')
-rw-r--r-- | ext/zlib/php_zlib.h | 1 | ||||
-rw-r--r-- | ext/zlib/zlib.c | 4 |
2 files changed, 4 insertions, 1 deletions
diff --git a/ext/zlib/php_zlib.h b/ext/zlib/php_zlib.h index 3d8c90cbf5..449dfed062 100644 --- a/ext/zlib/php_zlib.h +++ b/ext/zlib/php_zlib.h @@ -52,6 +52,7 @@ ZEND_BEGIN_MODULE_GLOBALS(zlib) int compression_coding; long output_compression; long output_compression_level; + long output_compression_default; char *output_handler; php_zlib_context *ob_gzhandler; ZEND_END_MODULE_GLOBALS(zlib); diff --git a/ext/zlib/zlib.c b/ext/zlib/zlib.c index 81a6361dd4..ff623924b1 100644 --- a/ext/zlib/zlib.c +++ b/ext/zlib/zlib.c @@ -890,6 +890,7 @@ static PHP_INI_MH(OnUpdate_zlib_output_compression) status = OnUpdateLong(entry, new_value, new_value_length, mh_arg1, mh_arg2, mh_arg3, stage TSRMLS_CC); + ZLIBG(output_compression) = ZLIBG(output_compression_default); if (stage == PHP_INI_STAGE_RUNTIME && int_value) { if (!php_output_handler_started(ZEND_STRL(PHP_ZLIB_OUTPUT_HANDLER_NAME) TSRMLS_CC)) { php_zlib_output_compression_start(TSRMLS_C); @@ -914,7 +915,7 @@ static PHP_INI_MH(OnUpdate_zlib_output_handler) /* {{{ INI */ PHP_INI_BEGIN() - STD_PHP_INI_BOOLEAN("zlib.output_compression", "0", PHP_INI_ALL, OnUpdate_zlib_output_compression, output_compression, zend_zlib_globals, zlib_globals) + STD_PHP_INI_BOOLEAN("zlib.output_compression", "0", PHP_INI_ALL, OnUpdate_zlib_output_compression, output_compression_default, zend_zlib_globals, zlib_globals) STD_PHP_INI_ENTRY("zlib.output_compression_level", "-1", PHP_INI_ALL, OnUpdateLong, output_compression_level, zend_zlib_globals, zlib_globals) STD_PHP_INI_ENTRY("zlib.output_handler", "", PHP_INI_ALL, OnUpdate_zlib_output_handler, output_handler, zend_zlib_globals, zlib_globals) PHP_INI_END() @@ -958,6 +959,7 @@ static PHP_MSHUTDOWN_FUNCTION(zlib) static PHP_RINIT_FUNCTION(zlib) { ZLIBG(compression_coding) = 0; + ZLIBG(output_compression) = ZLIBG(output_compression_default); php_zlib_output_compression_start(TSRMLS_C); |