From: Greg Beaver Date: Wed, 9 Jan 2008 08:12:26 +0000 (+0000) Subject: apply proper fix of bug #43793 to zlib.deflate (window+16 = gzip) X-Git-Tag: php-5.2.6RC1~184 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=8a1cd11e0b2dc36681d1ad1038f500d72b4717cc;p=php apply proper fix of bug #43793 to zlib.deflate (window+16 = gzip) --- diff --git a/ext/zlib/zlib_filter.c b/ext/zlib/zlib_filter.c index 566d60ef52..976c04d432 100644 --- a/ext/zlib/zlib_filter.c +++ b/ext/zlib/zlib_filter.c @@ -367,7 +367,7 @@ static php_stream_filter *php_zlib_filter_create(const char *filtername, zval *f /* log-2 base of history window (9 - 15) */ SEPARATE_ZVAL(tmpzval); convert_to_long_ex(tmpzval); - if (Z_LVAL_PP(tmpzval) < -MAX_WBITS || Z_LVAL_PP(tmpzval) > MAX_WBITS + 32) { + if (Z_LVAL_PP(tmpzval) < -MAX_WBITS || Z_LVAL_PP(tmpzval) > MAX_WBITS + 16) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid parameter give for window size. (%ld)", Z_LVAL_PP(tmpzval)); } else { windowBits = Z_LVAL_PP(tmpzval);