ID: 27211
Updated by: [EMAIL PROTECTED]
Reported By: glox at glox dot be
Status: Assigned
Bug Type: Documentation problem
Operating System: *
PHP Version: 5CVS-2004-02-12
Assigned To: nlopess
New Comment:
I had no time to fix this yet, but you should use something like:
$srv = stream_socket_server("udp://127.0.0.1:13");
do {
$pkt = stream_socket_recvfrom($srv, 1, 0, $peer);
stream_socket_sendto($srv, date("D M j H:i:s Y\r\n"), 0, $peer);
} while ($pkt !== false);
Previous Comments:
------------------------------------------------------------------------
[2004-06-02 22:28:50] flugelaar at pandora dot be
Is there news about this bug?
------------------------------------------------------------------------
[2004-04-30 13:53:39] i_kobayashi at rnk dot co dot jp
In communication by udp, it is not accept() but recvfrom(). However,
since there is no means to acquire an address and a port from
stream_socket_recvfrom(), a reply cannot be returned. Are there any of
other means?
------------------------------------------------------------------------
[2004-03-15 10:27:04] [EMAIL PROTECTED]
Shame on me, but I've lost the e-mails I've exchanged with Wez (my ISP
fault).
I don't remeber very well how to reproduce the crash :(
Wez sent me some examples to fix the ones that are currently in the
docs, but I've lost them... :-(
------------------------------------------------------------------------
[2004-03-15 10:20:55] [EMAIL PROTECTED]
Assigning to Nuno. (Please report the possible crash in different
report if you haven't done it already)
------------------------------------------------------------------------
[2004-02-16 05:16:36] [EMAIL PROTECTED]
*_accept() doesn't make sense for UDP (which is a connection*less*
protocol).
I had a conversation about this example with Nuno
this weekend; he will fix the docs. He also found
a segfault, but I don't have time to fix it right now.
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/27211
--
Edit this bug report at http://bugs.php.net/?id=27211&edit=1