From: Dmitry Stogov Date: Fri, 7 Nov 2014 07:24:25 +0000 (+0300) Subject: Merge branch 'PHP-5.6' X-Git-Tag: PRE_PHP7_REMOVALS~68 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=2afb5df4da4b27c42444a2ac9523b57c26e31459;p=php Merge branch 'PHP-5.6' * PHP-5.6: Fix opcache.revalidate_freq per-request behavior Conflicts: ext/opcache/ZendAccelerator.h --- 2afb5df4da4b27c42444a2ac9523b57c26e31459 diff --cc ext/opcache/ZendAccelerator.c index b5d446a54b,42b4e913b7..d79e42740d --- a/ext/opcache/ZendAccelerator.c +++ b/ext/opcache/ZendAccelerator.c @@@ -2346,13 -2628,10 +2339,9 @@@ static int accel_startup(zend_extensio * include_once/require_once statements */ accelerator_orig_zend_resolve_path = zend_resolve_path; zend_resolve_path = persistent_zend_resolve_path; -#endif - if (ZCG(accel_directives).validate_timestamps) { - ZCSG(revalidate_at) = zend_accel_get_time() + ZCG(accel_directives).revalidate_freq; - } - /* Override chdir() function */ - if (zend_hash_find(CG(function_table), "chdir", sizeof("chdir"), (void**)&func) == SUCCESS && + if ((func = zend_hash_str_find_ptr(CG(function_table), "chdir", sizeof("chdir")-1)) != NULL && func->type == ZEND_INTERNAL_FUNCTION) { orig_chdir = func->internal_function.handler; func->internal_function.handler = ZEND_FN(accel_chdir); diff --cc ext/opcache/ZendAccelerator.h index 28c3d21102,008e222e44..619ade025d --- a/ext/opcache/ZendAccelerator.h +++ b/ext/opcache/ZendAccelerator.h @@@ -266,11 -294,11 +266,10 @@@ typedef struct _zend_accel_shared_globa zend_accel_restart_reason restart_reason; zend_bool cache_status_before_restart; #ifdef ZEND_WIN32 - unsigned long mem_usage; - unsigned long restart_in; + LONGLONG mem_usage; + LONGLONG restart_in; #endif zend_bool restart_in_progress; - time_t revalidate_at; -#if ZEND_EXTENSION_API_NO > PHP_5_3_X_API_NO /* Interned Strings Support */ char *interned_strings_start; char *interned_strings_top;