mirror of
https://github.com/php/php-src.git
synced 2024-12-16 21:37:49 +08:00
opcache: print restart reason
This commit is contained in:
parent
aaaef22db6
commit
a4accc0e3e
@ -2921,11 +2921,18 @@ void accel_shutdown(void)
|
||||
|
||||
void zend_accel_schedule_restart(zend_accel_restart_reason reason)
|
||||
{
|
||||
const char *zend_accel_restart_reason_text[ACCEL_RESTART_USER + 1] = {
|
||||
"out of memory",
|
||||
"hash overflow",
|
||||
"user",
|
||||
};
|
||||
|
||||
if (ZCSG(restart_pending)) {
|
||||
/* don't schedule twice */
|
||||
return;
|
||||
}
|
||||
zend_accel_error(ACCEL_LOG_DEBUG, "Restart Scheduled!");
|
||||
zend_accel_error(ACCEL_LOG_DEBUG, "Restart Scheduled! Reason: %s",
|
||||
zend_accel_restart_reason_text[reason]);
|
||||
|
||||
SHM_UNPROTECT();
|
||||
ZCSG(restart_pending) = 1;
|
||||
|
Loading…
Reference in New Issue
Block a user