is there a way to 'flush' a socket's 'recv' buffer without using recv()?
hypothetical ... a client is sending 5 MB of via the send function(). my server tries to create a file to store it in prior to calling recv(), but fails. My server wants to respond with an 'internal error', and then continue the correspondence. It needs to clear the data it would collect via recv() (and probably tell the client to stop looping thru its buffer) instead of receiving all the data and THEN reporting an error. (assume said client is on a dialup).
imagine an SMTP server.