From: Operating system: Ubuntu 10.04 PHP version: 5.3.2 Package: PCNTL related Bug Type: Bug Bug description:pcntl_signal() restart_syscalls doesn't behave as expected
Description: ------------ The 3rd parameter of pcntl_signal() is "restart_syscalls". The docs provide very little information about it, however reading here http://www.win.tue.nl/~aeb/linux/lk/lk-4.html#ss4.5 shows that it should cause the following behaviour when a wait() call is made: "The effect is that upon an interrupt the system call is aborted, the user program's signal handler is called, and afterwards the system call is restarted from the beginning." The pcntl implementation of the restart_syscalls parameter appears to restart the syscalls *without* calling the userland signal handler. While I understand that this cannot be fixed (due to the "tick" based signal handling in PHP), the "restart_syscalls" parameter should not default to "true". If the default parameter value is not changed, at the very least a big red note should be made in the documentation warning of this inconsistency. Expected result: ---------------- restart_syscalls parameter, when true, should cause wait() calls to get restarted after calling the userland signal handler. Actual result: -------------- restart_syscalls parameter, when true, causes wait() calls to get restarted *without* calling the userland signal handler. -- Edit bug report at http://bugs.php.net/bug.php?id=52121&edit=1 -- Try a snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=52121&r=trysnapshot52 Try a snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=52121&r=trysnapshot53 Try a snapshot (trunk): http://bugs.php.net/fix.php?id=52121&r=trysnapshottrunk Fixed in SVN: http://bugs.php.net/fix.php?id=52121&r=fixed Fixed in SVN and need be documented: http://bugs.php.net/fix.php?id=52121&r=needdocs Fixed in release: http://bugs.php.net/fix.php?id=52121&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=52121&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=52121&r=needscript Try newer version: http://bugs.php.net/fix.php?id=52121&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=52121&r=support Expected behavior: http://bugs.php.net/fix.php?id=52121&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=52121&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=52121&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=52121&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=52121&r=php4 Daylight Savings: http://bugs.php.net/fix.php?id=52121&r=dst IIS Stability: http://bugs.php.net/fix.php?id=52121&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=52121&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=52121&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=52121&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=52121&r=mysqlcfg