mirror of
https://github.com/php/php-src.git
synced 2026-03-24 00:02:20 +01:00
Compile in opcache without COMPILE_IGNORE_INTERNAL_CLASSES (#15025)
This commit is contained in:
@@ -1809,13 +1809,20 @@ static zend_persistent_script *opcache_compile_file(zend_file_handle *file_handl
|
||||
zend_try {
|
||||
orig_compiler_options = CG(compiler_options);
|
||||
CG(compiler_options) |= ZEND_COMPILE_HANDLE_OP_ARRAY;
|
||||
CG(compiler_options) |= ZEND_COMPILE_IGNORE_INTERNAL_CLASSES;
|
||||
CG(compiler_options) |= ZEND_COMPILE_DELAYED_BINDING;
|
||||
CG(compiler_options) |= ZEND_COMPILE_NO_CONSTANT_SUBSTITUTION;
|
||||
CG(compiler_options) |= ZEND_COMPILE_IGNORE_OTHER_FILES;
|
||||
CG(compiler_options) |= ZEND_COMPILE_IGNORE_OBSERVER;
|
||||
#ifdef ZEND_WIN32
|
||||
/* On Windows, don't compile with internal classes. Shm may be attached from different
|
||||
* processes with internal classes living in different addresses. */
|
||||
CG(compiler_options) |= ZEND_COMPILE_IGNORE_INTERNAL_CLASSES;
|
||||
#endif
|
||||
if (ZCG(accel_directives).file_cache) {
|
||||
CG(compiler_options) |= ZEND_COMPILE_WITH_FILE_CACHE;
|
||||
/* Don't compile with internal classes for file cache, in case some extension is removed
|
||||
* later on. We cannot assume it is there in the future. */
|
||||
CG(compiler_options) |= ZEND_COMPILE_IGNORE_INTERNAL_CLASSES;
|
||||
}
|
||||
op_array = *op_array_p = accelerator_orig_compile_file(file_handle, type);
|
||||
CG(compiler_options) = orig_compiler_options;
|
||||
|
||||
Reference in New Issue
Block a user