Skip to content

Commit 6768235

Browse files
committed
Reinstall pcntl tick handler on each request (it cleared after the first request).
1 parent 3d05a6b commit 6768235

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ext/pcntl/pcntl.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -581,6 +581,7 @@ static PHP_GINIT_FUNCTION(pcntl)
581581

582582
PHP_RINIT_FUNCTION(pcntl)
583583
{
584+
php_add_tick_function(pcntl_signal_dispatch, NULL);
584585
zend_hash_init(&PCNTL_G(php_signal_table), 16, NULL, ZVAL_PTR_DTOR, 0);
585586
PCNTL_G(head) = PCNTL_G(tail) = PCNTL_G(spares) = NULL;
586587
PCNTL_G(async_signals) = 0;
@@ -591,7 +592,6 @@ PHP_MINIT_FUNCTION(pcntl)
591592
{
592593
php_register_signal_constants(INIT_FUNC_ARGS_PASSTHRU);
593594
php_pcntl_register_errno_constants(INIT_FUNC_ARGS_PASSTHRU);
594-
php_add_tick_function(pcntl_signal_dispatch, NULL);
595595
orig_interrupt_function = zend_interrupt_function;
596596
zend_interrupt_function = pcntl_interrupt_function;
597597

0 commit comments

Comments
 (0)