php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #58998 event_set & EV_SIGINT
Submitted: 2009-12-18 11:10 UTC Modified: 2010-06-23 04:23 UTC
From: fantom at fantom-lab dot ru Assigned:
Status: Closed Package: libevent (PECL)
PHP Version: 5.2.9 OS: FreeBSD
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: fantom at fantom-lab dot ru
New email:
PHP Version: OS:

 

 [2009-12-18 11:10 UTC] fantom at fantom-lab dot ru
Description:
------------
Not available work with signals, cause second param of event_set is "resource", but for signals must be integer.
Ex:
event_set($event, SIGINT, EV_SIGNAL | EV_PERSIST, 'func');


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-12-18 11:20 UTC] fantom at fantom-lab dot ru
Strange anomality

$eventBase = event_base_new();
...
$f = fopen(__FILE__, 'r');
$event = event_new();
function test(){ 
	echo "SIG!\n" ;
}
event_set($event, $f, EV_SIGNAL | EV_PERSIST, 'test');
event_base_set($event, $eventBase);
event_add($event);
...

then run script and send signal from terminal:
# kill -USR1 [prosess_id]

after that script print "SIG!" and break
 [2010-06-23 04:23 UTC] tony at daylessday dot org
Thank you for your bug report. This issue has been fixed
in the latest released version of the package, which you can download at
http://pecl.php.net/get/libevent

Fixed in 0.0.4.
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Tue Jan 14 03:01:30 2025 UTC