com php-src: Fixed possible caching with invalid key value: ext/opcache/ZendAccelerator.c

From: Date: Tue, 01 Sep 2015 09:56:33 +0000
Subject: com php-src: Fixed possible caching with invalid key value: ext/opcache/ZendAccelerator.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-88816@lists.php.net to get a copy of this message
Commit: d8eee72a840ef7e86c5f9cc0481a23f373daf96c Author: Dmitry Stogov <dmitry@zend.com> Tue, 1 Sep 2015 12:56:33 +0300 Parents: bb4b50636c86b8a2994a7d1e3c1925aa86146760 Branches: master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=d8eee72a840ef7e86c5f9cc0481a23f373daf96c Log: Fixed possible caching with invalid key value Changed paths: M ext/opcache/ZendAccelerator.c Diff: diff --git a/ext/opcache/ZendAccelerator.c b/ext/opcache/ZendAccelerator.c index 01e9eca..905700e 100644 --- a/ext/opcache/ZendAccelerator.c +++ b/ext/opcache/ZendAccelerator.c @@ -917,13 +917,16 @@ char *accel_make_persistent_key(const char *path, int path_length, int *key_len) /* CWD and include_path don't matter for absolute file names and streams */ if (IS_ABSOLUTE_PATH(path, path_length)) { /* pass */ + ZCG(key_len) = 0; } else if (UNEXPECTED(is_stream_path(path))) { if (!is_cacheable_stream_path(path)) { return NULL; } /* pass */ + ZCG(key_len) = 0; } else if (UNEXPECTED(!ZCG(accel_directives).use_cwd)) { /* pass */ + ZCG(key_len) = 0; } else { const char *include_path = NULL, *cwd = NULL; int include_path_len = 0, cwd_len = 0;

« previous php.cvs (#88816) next »