|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2011-02-16 16:53 UTC] evert at rooftopsolutions dot nl
[2013-01-25 08:53 UTC] tony2001@php.net
-Status: Open
+Status: Assigned
-Assigned To:
+Assigned To: tony2001
[2013-01-31 19:04 UTC] tony2001@php.net
-Status: Assigned
+Status: Not a bug
[2013-01-31 19:04 UTC] tony2001@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Nov 02 00:00:01 2025 UTC |
Description: ------------ When using event_base_loop with the flag EVLOOP_NONBLOCK, the callback doesn't seem to be called. Reproduce code: --------------- <?php $base = event_base_new(); $event = event_new(); event_set($event, STDIN, EV_READ, "ev_read", array($event, $base)); event_base_set($event, $base); event_add($event); event_base_loop($base, EVLOOP_NONBLOCK); for ($i = 10000000; $i > 0; $i--) { // do something here } echo "End\n"; function ev_read($fd, $events, $arg = null) { $data = trim(fgets($fd)); echo "read: [" . $data . "]\n"; } --- $ php example.php foo Expected result: ---------------- foo read: [foo] End Actual result: -------------- foo End $ foo foo: command not found