com php-src: Fixed bug #71561 (NULL pointer dereference in Zip::ExtractTo): NEWS ext/zip/php_zip.c

From: Date: Tue, 09 Feb 2016 15:32:20 +0000
Subject: com php-src: Fixed bug #71561 (NULL pointer dereference in Zip::ExtractTo): NEWS ext/zip/php_zip.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-90976@lists.php.net to get a copy of this message
Commit: f45752eb8393ebe758d8e920f7a48a2a39aa6ea5 Author: Xinchen Hui <laruence@gmail.com> Tue, 9 Feb 2016 23:32:20 +0800 Parents: 5fdfab743d964bb13602effc9efcd6f747e2f58c Branches: PHP-5.6 PHP-7.0 Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=f45752eb8393ebe758d8e920f7a48a2a39aa6ea5 Log: Fixed bug #71561 (NULL pointer dereference in Zip::ExtractTo) Bugs: https://bugs.php.net/71561 Changed paths: M NEWS M ext/zip/php_zip.c Diff: diff --git a/NEWS b/NEWS index 0fc0565..a13c4b2 100644 --- a/NEWS +++ b/NEWS @@ -20,6 +20,9 @@ PHP NEWS - Standard: . Fixed bug #70720 (strip_tags improper php code parsing). (Julien) +- Zip: + . Fixed bug #71561 (NULL pointer dereference in Zip::ExtractTo). (Laruence) + 04 Feb 2016, PHP 5.6.18 - Core: diff --git a/ext/zip/php_zip.c b/ext/zip/php_zip.c index d040d20..ccd0467 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; } }

« previous php.cvs (#90976) next »