Merge branch 'PHP-5.5' into PHP-5.6

* PHP-5.5:
  Fixed opcahce_reset() crash when opcache.protect_memory is set
This commit is contained in:
Dmitry Stogov 2013-11-26 21:59:02 +04:00
commit 834eaae52d

View File

@ -2734,6 +2734,7 @@ void zend_accel_schedule_restart(zend_accel_restart_reason reason TSRMLS_DC)
}
zend_accel_error(ACCEL_LOG_DEBUG, "Restart Scheduled!");
SHM_UNPROTECT();
ZCSG(restart_pending) = 1;
ZCSG(restart_reason) = reason;
ZCSG(cache_status_before_restart) = ZCSG(accelerator_enabled);
@ -2744,6 +2745,7 @@ void zend_accel_schedule_restart(zend_accel_restart_reason reason TSRMLS_DC)
} else {
ZCSG(force_restart_time) = 0;
}
SHM_PROTECT();
}
/* this is needed because on WIN32 lock is not decreased unless ZCG(counted) is set */