diff options
author | Xinchen Hui <laruence@gmail.com> | 2016-02-09 23:32:20 +0800 |
---|---|---|
committer | Xinchen Hui <laruence@gmail.com> | 2016-02-09 23:32:20 +0800 |
commit | f45752eb8393ebe758d8e920f7a48a2a39aa6ea5 (patch) | |
tree | 7f95233f1755e86079b73c514e4c720e87dd7a2f /ext/zip | |
parent | 5fdfab743d964bb13602effc9efcd6f747e2f58c (diff) | |
download | php-git-f45752eb8393ebe758d8e920f7a48a2a39aa6ea5.tar.gz |
Fixed bug #71561 (NULL pointer dereference in Zip::ExtractTo)
Diffstat (limited to 'ext/zip')
-rw-r--r-- | ext/zip/php_zip.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/zip/php_zip.c b/ext/zip/php_zip.c index d040d206d1..ccd0467fd3 100644 --- a/ext/zip/php_zip.c +++ b/ext/zip/php_zip.c @@ -2713,7 +2713,7 @@ static ZIPARCHIVE_METHOD(extractTo) for (i = 0; i < filecount; i++) { char *file = (char*)zip_get_name(intern, i, ZIP_FL_UNCHANGED); - if (!php_zip_extract_file(intern, pathto, file, strlen(file) TSRMLS_CC)) { + if (!file || !php_zip_extract_file(intern, pathto, file, strlen(file) TSRMLS_CC)) { RETURN_FALSE; } } |