cellog Sat Jan 12 22:28:04 2008 UTC
Modified files:
/php-src/ext/zlib zlib_filter.c
Log:
wrong file version merged in fix for Bug #40189, here is the correct fix
http://cvs.php.net/viewvc.cgi/php-src/ext/zlib/zlib_filter.c?r1=1.21&r2=1.22&diff_format=u
Index: php-src/ext/zlib/zlib_filter.c
diff -u php-src/ext/zlib/zlib_filter.c:1.21 php-src/ext/zlib/zlib_filter.c:1.22
--- php-src/ext/zlib/zlib_filter.c:1.21 Sat Jan 12 22:03:44 2008
+++ php-src/ext/zlib/zlib_filter.c Sat Jan 12 22:28:04 2008
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zlib_filter.c,v 1.21 2008/01/12 22:03:44 cellog Exp $ */
+/* $Id: zlib_filter.c,v 1.22 2008/01/12 22:28:04 cellog Exp $ */
#include "php.h"
#include "php_zlib.h"
@@ -106,7 +106,7 @@
data->strm.avail_in = 0;
bin += desired;
- if (status == Z_STREAM_END || data->strm.avail_out <
data->outbuf_len) {
+ if (data->strm.avail_out < data->outbuf_len) {
php_stream_bucket *out_bucket;
size_t bucketlen = data->outbuf_len -
data->strm.avail_out;
out_bucket = php_stream_bucket_new(stream,
estrndup(data->outbuf, bucketlen), bucketlen, 1, 0 TSRMLS_CC);
@@ -114,12 +114,12 @@
data->strm.avail_out = data->outbuf_len;
data->strm.next_out = data->outbuf;
exit_status = PSFS_PASS_ON;
- if (status == Z_STREAM_END &&
data->strm.avail_out >= data->outbuf_len) {
- /* no more data to decompress, and
nothing was spat out */
- php_stream_bucket_delref(bucket
TSRMLS_CC);
- return PSFS_PASS_ON;
- }
+ } else if (status == Z_STREAM_END &&
data->strm.avail_out >= data->outbuf_len) {
+ /* no more data to decompress, and nothing was
spat out */
+ php_stream_bucket_delref(bucket TSRMLS_CC);
+ return PSFS_PASS_ON;
}
+
}
consumed += bucket->buflen;
php_stream_bucket_delref(bucket TSRMLS_CC);
--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php