LimpCheese Posted October 27, 2006 Share Posted October 27, 2006 Can someone show me an example of how to create a non-blocking socket for a SOCKET_STREAM over tcp. When I use the following code I get "A non-blocking operation could not be completed immediately." error. Thank in advance.[code] $socket = socket_create(AF_INET, SOCK_RAW, SOL_TCP); socket_set_nonblock($socket); socket_connect($socket,"news.csh.rit.edu",119); //ERROR OCCURS ON THIS LINE socket_recv($socket,$buf,1024,0); echo $buf;[/code] Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.