summaryrefslogtreecommitdiff
path: root/ext/bz2
diff options
context:
space:
mode:
authorAntony Dovgal <tony2001@php.net>2006-12-25 20:03:43 +0000
committerAntony Dovgal <tony2001@php.net>2006-12-25 20:03:43 +0000
commit35db4d21b0f6ef6393941a1a6a7bd036a572ce5e (patch)
tree55f52eacae8fc80ae44cfadef6f6ffb10aa3097a /ext/bz2
parent4480c5eb5d7adf4437237066ad9eda70d47979b6 (diff)
downloadphp-git-35db4d21b0f6ef6393941a1a6a7bd036a572ce5e.tar.gz
MFH
Diffstat (limited to 'ext/bz2')
-rw-r--r--ext/bz2/bz2.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/bz2/bz2.c b/ext/bz2/bz2.c
index 4b76fc2871..90ab5c8c0f 100644
--- a/ext/bz2/bz2.c
+++ b/ext/bz2/bz2.c
@@ -330,7 +330,7 @@ static 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;
}