diff options
Diffstat (limited to 'ext/opcache/zend_accelerator_module.c')
-rw-r--r-- | ext/opcache/zend_accelerator_module.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/ext/opcache/zend_accelerator_module.c b/ext/opcache/zend_accelerator_module.c index 979a730238..f7715a266b 100644 --- a/ext/opcache/zend_accelerator_module.c +++ b/ext/opcache/zend_accelerator_module.c @@ -324,14 +324,16 @@ static int filename_is_in_cache(char *filename, int filename_len TSRMLS_DC) persistent_script = zend_accel_hash_find(&ZCSG(hash), filename, filename_len + 1); if (persistent_script) { return !persistent_script->corrupted && - validate_timestamp_and_record(persistent_script, &handle TSRMLS_CC) == SUCCESS; + (!ZCG(accel_directives).validate_timestamps || + validate_timestamp_and_record(persistent_script, &handle TSRMLS_CC) == SUCCESS); } } if ((key = accel_make_persistent_key_ex(&handle, filename_len, &key_length TSRMLS_CC)) != NULL) { persistent_script = zend_accel_hash_find(&ZCSG(hash), key, key_length + 1); return persistent_script && !persistent_script->corrupted && - validate_timestamp_and_record(persistent_script, &handle TSRMLS_CC) == SUCCESS; + (!ZCG(accel_directives).validate_timestamps || + validate_timestamp_and_record(persistent_script, &handle TSRMLS_CC) == SUCCESS); } return 0; |