|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #47816 pcntl tests failing on NetBSD
Submitted: 2009-03-28 01:43 UTC Modified: 2009-03-28 19:08 UTC
From: Assigned: mbeccati (profile)
Status: Closed Package: PCNTL related
PHP Version: 5.3CVS-2009-03-28 (CVS) OS: NetBSD 4
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
Solve the problem:
19 - 5 = ?
Subscribe to this entry?

 [2009-03-28 01:43 UTC]
There are a few problems with the new pcntl extension on my NetBSD 4.0 system. The extension compiles fine, but a few tests fail.

First, it seems that NetBSD sigtimedwait / sigwaitinfo implementations return 0 on success and -1 on failure, rather then the signal number: see

A patch is available here:

I didn't commit myself as you might want a better (autoconf based?) fix.

Second, there are a couple of kernel bugs interfering with pcntl properly working: (Fixed in -current) (Under investigation)

Once those bugs have been fixed the extensions should be properly working on NetBSD.

Reproduce code:
pcntl_sigprocmask(SIG_BLOCK, array(SIGTERM));
posix_kill(posix_getpid(), SIGTERM);
var_dump(pcntl_sigwaitinfo(array(SIGTERM), $siginfo));

Expected result:
array(3) {

Actual result:


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2009-03-28 03:08 UTC]

This looks good, please commit :)

Thanks for your tests on NetBSD.

 [2009-03-28 19:08 UTC]
This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
Thank you for the report, and for helping us make PHP better.

PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Jun 13 20:01:31 2024 UTC