note 115400 added to function.stream-select
| From: | rob at associatedtechs dot com | Date: | Fri, 18 Jul 2014 12:26:21 +0000 |
| Subject: | note 115400 added to function.stream-select | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-199967@lists.php.net to get a copy of this message | ||
If you try to use stream_select() with fread(), you may get bit by a combination of bugs
(https://bugs.php.net/bug.php?id=52602 and https://bugs.php.net/bug.php?id=51056). As of PHP
5.5.10, fread() and stream_select() don't reliably play well together.
If you need stream_select() and you don't need an encrypted connection (e.g. TLS), use
stream_socket_recvfrom() instead of fread().
I can't find a way to reliably handle an encrypted connection with blocking functions in PHP;
non-blocking might be the only way to do it.
----
Server IP: 72.52.91.14
Probable Submitter: 66.55.134.214
----
Manual Page -- http://php.net/manual/en/function.stream-select.php
Edit -- https://master.php.net/note/edit/115400
Del: integrated -- https://master.php.net/note/delete/115400/integrated
Del: useless -- https://master.php.net/note/delete/115400/useless
Del: bad code -- https://master.php.net/note/delete/115400/bad+code
Del: spam -- https://master.php.net/note/delete/115400/spam
Del: non-english -- https://master.php.net/note/delete/115400/non-english
Del: in docs -- https://master.php.net/note/delete/115400/in+docs
Del: other reasons-- https://master.php.net/note/delete/115400
Reject -- https://master.php.net/note/reject/115400
Search -- https://master.php.net/manage/user-notes.php