summaryrefslogtreecommitdiff
path: root/ext/opcache/zend_accelerator_module.c
diff options
context:
space:
mode:
authorChristoph M. Becker <cmbecker69@gmx.de>2019-09-16 16:01:49 +0200
committerChristoph M. Becker <cmbecker69@gmx.de>2019-09-16 16:01:49 +0200
commit9b9fac78b033e8b26d24cf35d69b603ca84a61d2 (patch)
treefd0141ce3a8cd28e4b58c85080d3243ab7632c9b /ext/opcache/zend_accelerator_module.c
parente6b1f9d56da62acce9010193ef34f2b87635f5d6 (diff)
parent20f73d3d8f2f2664288d1e70930f047605bfb44f (diff)
downloadphp-git-9b9fac78b033e8b26d24cf35d69b603ca84a61d2.tar.gz
Merge branch 'PHP-7.4'
* PHP-7.4: Fix #78429: opcache_compile_file(__FILE__); segfaults
Diffstat (limited to 'ext/opcache/zend_accelerator_module.c')
-rw-r--r--ext/opcache/zend_accelerator_module.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/ext/opcache/zend_accelerator_module.c b/ext/opcache/zend_accelerator_module.c
index 643f1d6cd0..9faec50386 100644
--- a/ext/opcache/zend_accelerator_module.c
+++ b/ext/opcache/zend_accelerator_module.c
@@ -867,6 +867,11 @@ static ZEND_FUNCTION(opcache_compile_file)
return;
}
+ if (!accel_startup_ok) {
+ zend_error(E_NOTICE, ACCELERATOR_PRODUCT_NAME " has not been properly started, can't compile file");
+ RETURN_FALSE;
+ }
+
zend_stream_init_filename(&handle, script_name);
orig_execute_data = EG(current_execute_data);