Skip to content

Commit 08f8621

Browse files
author
Jani Taskinen
committed
- Fixed bug #48994 (zlib.output_compression does not ouput HTTP headers when set to a string value)
# also fixes bug #35936 (ini.zlib.output-compression Documentation :)
1 parent d744463 commit 08f8621

File tree

3 files changed

+5
-1
lines changed

3 files changed

+5
-1
lines changed

NEWS

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,8 @@ PHP NEWS
3838
a chunk). (andreas dot streichardt at globalpark dot com, Ilia)
3939
- Fixed bug #49000 (PHP CLI in Interactive mode (php -a) crashes
4040
when including files from function). (Stas)
41+
- Fixed bug #48994 (zlib.output_compression does not ouput HTTP headers when
42+
set to a string value). (Jani)
4143
- Fixed bug #48980 (Crash when compiling with pdo_firebird). (Felipe)
4244
- Fixed bug #48962 (cURL does not upload files with specified filename).
4345
(Ilia)

ext/zlib/php_zlib.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,8 @@ ZEND_BEGIN_MODULE_GLOBALS(zlib)
3535
char *output_handler;
3636
ZEND_END_MODULE_GLOBALS(zlib)
3737

38+
PHPAPI ZEND_EXTERN_MODULE_GLOBALS(zlib)
39+
3840
extern php_stream_filter_factory php_zlib_filter_factory;
3941
extern zend_module_entry php_zlib_module_entry;
4042
#define zlib_module_ptr &php_zlib_module_entry

main/SAPI.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -793,7 +793,7 @@ SAPI_API int sapi_send_headers(TSRMLS_D)
793793
/* Add output compression headers at this late stage in order to make
794794
it possible to switch it off inside the script. */
795795

796-
if (zend_ini_long("zlib.output_compression", sizeof("zlib.output_compression"), 0)) {
796+
if (ZLIBG(output_compression)) {
797797
zval nm_zlib_get_coding_type;
798798
zval *uf_result = NULL;
799799

0 commit comments

Comments
 (0)