|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2009-04-15 16:50 UTC] nyim at 163 dot com
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Dec 04 09:00:01 2025 UTC |
Description: ------------ stream_set_timeout($udp, 0,300); just like stream_set_timeout($udp, 0); it ignore the third parameter strace the process: poll([{fd=3, events=POLLIN|POLLERR|POLLHUP, revents=POLLERR}], 1, 0) = 1 Reproduce code: --------------- <?php $udp = stream_socket_client("udp://127.0.0.1:3434"); fwrite($udp,'xx'); stream_set_timeout($udp, 0,300); $time = microtime(true); fread($udp,1500); echo microtime(true) - $time; Expected result: ---------------- 0.30182409286499 Actual result: -------------- 3.3140182495117E-5