[SDL] Non-blocking calls in SDL_net?

Jorge Garcia gdl at ac.uma.es
Sun Feb 22 18:59:27 PST 2004


Is there any way to make non-blocking calls in SDL_net? It seems that 
send/receive calls wait until everything is sent or received, and you cannot 
know how many bytes are available for sending/receiving before calling. If you 
use socket sets and check them you are only guaranteed that one byte(?) is 
available and asking for more bytes in a receive call may block the thread. 
AFAIK, some socket implementations allow a non-blocking mode which is very handy 
if you don't want to mess with threads.

  Jorge







More information about the SDL mailing list