Skip to content

Commit 935d922

Browse files
committed
"opcache.validate_root" is useless on Windows
1 parent 8202b97 commit 935d922

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

ext/opcache/ZendAccelerator.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,9 @@ typedef struct _zend_accel_directives {
231231
zend_bool inherited_hack;
232232
zend_bool enable_cli;
233233
zend_bool validate_permission;
234+
#ifndef ZEND_WIN32
234235
zend_bool validate_root;
236+
#endif
235237
unsigned long revalidate_freq;
236238
unsigned long file_update_protection;
237239
char *error_log;

ext/opcache/zend_accelerator_module.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,9 @@ ZEND_INI_BEGIN()
256256
STD_PHP_INI_BOOLEAN("opcache.use_cwd" , "1", PHP_INI_SYSTEM, OnUpdateBool, accel_directives.use_cwd , zend_accel_globals, accel_globals)
257257
STD_PHP_INI_BOOLEAN("opcache.validate_timestamps", "1", PHP_INI_ALL , OnUpdateBool, accel_directives.validate_timestamps, zend_accel_globals, accel_globals)
258258
STD_PHP_INI_BOOLEAN("opcache.validate_permission", "0", PHP_INI_SYSTEM, OnUpdateBool, accel_directives.validate_permission, zend_accel_globals, accel_globals)
259+
#ifndef ZEND_WIN32
259260
STD_PHP_INI_BOOLEAN("opcache.validate_root" , "0", PHP_INI_SYSTEM, OnUpdateBool, accel_directives.validate_root , zend_accel_globals, accel_globals)
261+
#endif
260262
STD_PHP_INI_BOOLEAN("opcache.inherited_hack" , "1", PHP_INI_SYSTEM, OnUpdateBool, accel_directives.inherited_hack , zend_accel_globals, accel_globals)
261263
STD_PHP_INI_BOOLEAN("opcache.dups_fix" , "0", PHP_INI_ALL , OnUpdateBool, accel_directives.ignore_dups , zend_accel_globals, accel_globals)
262264
STD_PHP_INI_BOOLEAN("opcache.revalidate_path" , "0", PHP_INI_ALL , OnUpdateBool, accel_directives.revalidate_path , zend_accel_globals, accel_globals)
@@ -666,7 +668,9 @@ static ZEND_FUNCTION(opcache_get_configuration)
666668
add_assoc_bool(directives, "opcache.use_cwd", ZCG(accel_directives).use_cwd);
667669
add_assoc_bool(directives, "opcache.validate_timestamps", ZCG(accel_directives).validate_timestamps);
668670
add_assoc_bool(directives, "opcache.validate_permission", ZCG(accel_directives).validate_permission);
671+
#ifndef ZEND_WIN32
669672
add_assoc_bool(directives, "opcache.validate_root", ZCG(accel_directives).validate_root);
673+
#endif
670674
add_assoc_bool(directives, "opcache.inherited_hack", ZCG(accel_directives).inherited_hack);
671675
add_assoc_bool(directives, "opcache.dups_fix", ZCG(accel_directives).ignore_dups);
672676
add_assoc_bool(directives, "opcache.revalidate_path", ZCG(accel_directives).revalidate_path);

0 commit comments

Comments
 (0)