diff options
author | Stanislav Malyshev <stas@php.net> | 2018-04-22 20:28:35 -0700 |
---|---|---|
committer | Stanislav Malyshev <stas@php.net> | 2018-04-22 20:28:35 -0700 |
commit | 83e7618f05cea9ad8ef17dfc5cbf05939a5d63dd (patch) | |
tree | fc4979e1ee10a15f6402143c0a6f0d18e9823293 | |
parent | 98e43a33c88b2d0839ca0857385a7bd0ee545880 (diff) | |
parent | ff83c00715f6e036da5e5b627a742d2697871ae1 (diff) | |
download | php-git-83e7618f05cea9ad8ef17dfc5cbf05939a5d63dd.tar.gz |
Merge branch 'PHP-7.1' into PHP-7.2
* PHP-7.1:
Add a bit of defensive conding for bug #76155
-rw-r--r-- | ext/phar/phar.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/phar/phar.c b/ext/phar/phar.c index 3cd29f6506..961be29fd3 100644 --- a/ext/phar/phar.c +++ b/ext/phar/phar.c @@ -1835,7 +1835,7 @@ static int phar_check_str(const char *fname, const char *ext_str, int ext_len, i char test[51]; const char *pos; - if (ext_len >= 50) { + if (ext_len < 0 || ext_len >= 50) { return FAILURE; } |