|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #78619 PHP7.4RC2 ZTS zend_signal_handler_defer crashes on apache shutdown
Submitted: 2019-10-01 10:22 UTC Modified: 2019-11-07 10:56 UTC
Avg. Score:4.5 ± 0.5
Reproduced:2 of 2 (100.0%)
Same Version:1 (50.0%)
Same OS:1 (50.0%)
From: pawel dot filipczak at dynatrace dot com Assigned: krakjoe (profile)
Status: Assigned Package: Apache2 related
PHP Version: 7.4.0RC2 OS: Linux x64
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2019-10-01 10:22 UTC] pawel dot filipczak at dynatrace dot com
On Apache/2.4.7 (Unix) PHP/7.4.0RC2

Thread Safe

apache start
open phpinfo test script
send SIGINT to apache master process 

To reproduce, download and call

Test script:


Expected result:
exit code 0

Actual result:
(gdb) bt
#0  0x00007f4b8024c72b in zend_signal_handler_defer (signo=1, siginfo=0x7f4b1dffa7f0, context=0x7f4b1dffa6c0) at /php-src-php-7.4.0RC2/Zend/zend_signal.c:95
#1  <signal handler called>
#2  0x00007f4b8cbd6bb7 in epoll_wait (epfd=8, events=0x1130230, maxevents=50, timeout=100) at ../sysdeps/unix/sysv/linux/epoll_wait.c:30
#3  0x00007f4b8d72c7e1 in impl_pollset_poll (pollset=0x1130188, timeout=<optimized out>, num=0x7f4b1dffaeb8, descriptors=0x7f4b1dffae98) at poll/unix/epoll.c:256
#4  0x00000000004687a3 in listener_thread (thd=0x1131060, dummy=<optimized out>) at event.c:1460
#5  0x00007f4b8d0b16db in start_thread (arg=0x7f4b1dffb700) at pthread_create.c:463
#6  0x00007f4b8cbd688f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2019-10-01 10:36 UTC]
Possibly relevant info - it appears that the way that PHP shuts down may have changed in PHP 7.4, and as far as I understand it, it appears that thread local storage is being destroyed before all the created threads are terminated. 

This was seen in Imagick for people using OpenMP - . For that, a hack appears to prevent the problem, which will be replaced by a proper solution when omp_pause_resource_all() is available on more systems.

That might be relevant, or not.
 [2019-11-07 10:56 UTC]
-Assigned To: +Assigned To: krakjoe
 [2019-11-07 10:56 UTC]
Possibly related to

Maybe krakjoe has an idea?
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 25 15:01:30 2024 UTC