From: Antony Dovgal Date: Mon, 25 Dec 2006 20:04:23 +0000 (+0000) Subject: MFH X-Git-Tag: php-4.4.5RC1~25 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=b307db4b1c0fca0a3e3a1f86cadbadc386cf0570;p=php MFH --- diff --git a/ext/bz2/bz2.c b/ext/bz2/bz2.c index b9333f7752..e4a08773d8 100644 --- a/ext/bz2/bz2.c +++ b/ext/bz2/bz2.c @@ -269,7 +269,7 @@ PHP_FUNCTION(bzread) php_stream_from_zval(stream, &bz); - if (len < 0) { + if ((len + 1) < 1) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "length may not be negative"); RETURN_FALSE; }