From 2345d2698957686d132ff5d4c536fc19dee61274 Mon Sep 17 00:00:00 2001 From: Greg Beaver Date: Wed, 9 Jan 2008 07:03:48 +0000 Subject: [PATCH] apply same fix of bug #43793 to zlib.deflate --- ext/zlib/zlib_filter.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/zlib/zlib_filter.c b/ext/zlib/zlib_filter.c index 46eb30b0ed..68d9b15f7d 100644 --- a/ext/zlib/zlib_filter.c +++ b/ext/zlib/zlib_filter.c @@ -379,7 +379,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) { + if (Z_LVAL_PP(tmpzval) < -MAX_WBITS || Z_LVAL_PP(tmpzval) > MAX_WBITS + 32) { 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); -- 2.40.0