Bug #81577 [NEW]: Segfault when signal handler raising a fatal error interrupts sleep+negation

From: Date: Sun, 31 Oct 2021 08:42:52 +0000
Subject: Bug #81577 [NEW]: Segfault when signal handler raising a fatal error interrupts sleep+negation
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-237476@lists.php.net to get a copy of this message
From:             abecker at mailbox dot org
Operating system: Linux
PHP version:      8.0.12
Package:          Reproducible crash
Bug Type:         Bug
Bug description:Segfault when signal handler raising a fatal error interrupts sleep+negation

Description:
------------
Run the test script on the command line and press Ctrl+C. The program
will crash.

A crash will occur if sleep is interrupted by the faulty signal handler
and
a negation of any variable with any value follows immediately. Negation
of
a constant will not result in a crash.

Test script:
---------------
pcntl_async_signals(true);
pcntl_signal(SIGINT, function() { 0/0; });
sleep(10);
! $anyVariableWithAnyValue;



-- 
Edit bug report at https://bugs.php.net/bug.php?id=81577&edit=1
-- 
Fix committed:                    https://bugs.php.net/fix.php?id=81577&r=fixed
Fixed in release:                 https://bugs.php.net/fix.php?id=81577&r=alreadyfixed
Need backtrace:                   https://bugs.php.net/fix.php?id=81577&r=needtrace
Need Reproduce Script:            https://bugs.php.net/fix.php?id=81577&r=needscript
Try newer version:                https://bugs.php.net/fix.php?id=81577&r=oldversion
Not developer issue:              https://bugs.php.net/fix.php?id=81577&r=support
Expected behavior:                https://bugs.php.net/fix.php?id=81577&r=notwrong
Not enough info:                  https://bugs.php.net/fix.php?id=81577&r=notenoughinfo
Submitted twice:                  https://bugs.php.net/fix.php?id=81577&r=submittedtwice
register_globals:                 https://bugs.php.net/fix.php?id=81577&r=globals
PHP version support discontinued: https://bugs.php.net/fix.php?id=81577&r=phptooold
Daylight Savings:                 https://bugs.php.net/fix.php?id=81577&r=dst
IIS Stability:                    https://bugs.php.net/fix.php?id=81577&r=isapi
Install GNU Sed:                  https://bugs.php.net/fix.php?id=81577&r=gnused
Floating point limitations:       https://bugs.php.net/fix.php?id=81577&r=float
No Zend Extensions:               https://bugs.php.net/fix.php?id=81577&r=nozend
MySQL Configuration Error:        https://bugs.php.net/fix.php?id=81577&r=mysqlcfg


Thread (6 messages)

« previous php.bugs (#237476) next »