Advertisement

recv

Started by October 11, 2002 12:01 PM
1 comment, last by Leadorn 22 years, 3 months ago
Hi I want to MSG_PEEK a socket, but i dont want recv to stay in there. how do i do that recv(socket,buffer,MSG_PEEK);
Nobody?
Advertisement
Sockets are blocking by default, but you can change the behavior using ioctlsocket:

u_long arg = 1 ; // 1 enables non-blocking and
// 0 enables blocking mode.
ioctlsocket (mysocket, FIONBIO, &arg) ;
// check for errors...


/jonas

This topic is closed to new replies.

Advertisement