Show quoted text 13 lines
Ludo Brands
Fri Apr 26 19:25:52 CEST 2013
If your socket is in blocking mode and you don't want your thread to
block, yes. Server or client, there is no difference.
The same for send. When you have a small block to send that fits in the
socket buffer and the socket buffer is empty, send will return
immediately. But if you have more data to send, your second send will
block until the first send is completed.
The same select can be used to return when the recv buffer is not empty
or the send buffer empty or when an exception occurs. See
http://linux.die.net/man/2/select
Ludo
I had not seen this reply, thanks for the explanation, Ludo. :)
Silvio Clécio
My public projects - github.com/silvioprog
