ID: 26362
Updated by: [email]sniperphp.net[/email]
Reported By: gunnar dot peipman at mail dot ee
-Status: Open
+Status: Feedback
Bug Type: Sockets related
Operating System: Windows XP Pro
PHP Version: 4.3.4
New Comment:

Provide short but COMPLETE example script.



Previous Comments:
------------------------------------------------------------------------

[2003-11-22 23:26:49] gunnar dot peipman at mail dot ee

Sorry, forgot to mention that $gSOCKARRAY is array with one socket
pointer. ($gSOCKARRAY=array($gSOCK_POINTER)).

------------------------------------------------------------------------

[2003-11-22 23:24:43] gunnar dot peipman at mail dot ee

Description:
------------
When using non-blocking sockets I get the following error:

Warning: stream_select(): unable to select [0]: No error in
<b>c:\web\www\bot\bot\mod.eval.php(17).



Reproduce code:
---------------
Open stream to IRC server and after getting connection and identifying
the script try to use the following code:

error_reporting(E_ALL);
echo (stream_select($gSOCKARRAY, $write=NULL, $except=NULL, 1,
1)===false);

Expected result:
----------------
I expect that for false there is no changes and for true there is some
socket I have to test.

Actual result:
--------------
All I get is the warning above. I tried to change timeouts but no luck
at all. Still apache eats about 78% of my CPU.


------------------------------------------------------------------------


--
Edit this bug report at [url]http://bugs.php.net/?id=26362&edit=1[/url]