select() in conjunction with recvfrom()
-
I am a little confused about how exactly these two functions can work with each other. I would like to make a call to select and then make a call to recvfrom() so as to allow for a timeout period. So if my socket does not recvfrom() anything within lets say four seconds then I need to send a "timed out" error to the output box. I have read the msdn reference on select() but I don't really understand. Thank you, Eric Sepich
-
I am a little confused about how exactly these two functions can work with each other. I would like to make a call to select and then make a call to recvfrom() so as to allow for a timeout period. So if my socket does not recvfrom() anything within lets say four seconds then I need to send a "timed out" error to the output box. I have read the msdn reference on select() but I don't really understand. Thank you, Eric Sepich
The best resource I can give you is the Winsock Programmer's FAQ[^].
select
tells you when there is data waiting to be read from a socket, or when data can be written to a socket, or when a socket is in an error state.