don't optimize script if it's not going to be cached

This commit is contained in:
Dmitry Stogov 2013-03-28 13:45:40 +04:00
parent 037ea6f360
commit 3ae5c55596

View File

@ -2686,7 +2686,11 @@ static void accel_op_array_handler(zend_op_array *op_array)
{
TSRMLS_FETCH();
if (ZCG(enabled) && accel_startup_ok && ZCSG(accelerator_enabled)) {
if (ZCG(enabled) &&
accel_startup_ok &&
ZCSG(accelerator_enabled) &&
!ZSMMG(memory_exhausted) &&
!ZCSG(restart_pending)) {
zend_optimizer(op_array TSRMLS_CC);
}
}