Hello

I have a nonblocking socket and I want to do recv(). Im being confused because I know when socket is readable it can receive some data that can be only a part of the whole data..

How should I know there is more data waiting to come so that I would store what I just got in the buffer and wait for next part of data and then process all what I got?

Thanks for help