Menu

Er.. help! (recv infinite loop)

Help
2004-11-22
2013-04-08
  • Peter Laurens

    Peter Laurens - 2004-11-22

    Er hi...

    I know this forum is completely empty.. still I hope there is someone out there who can help me...

    My problem is this...

    From the readData: method inside AbstractSocket.m, there is the following (key) line:

        // Request a read of as much as we can.  Should return immediately if no data.
      
        count = recv(socketfd, readBuffer, readBufferSize, 0);

    The only thing is, the code seems to do exactly the opposite of what the comment promises it will do. If there is no data at the other end then it'll hang forever and ever at this line! I am really stuck, very frustrated have tried many things, any help would be great - if yo need more info, just let me know.

    I hope I'm not typing into the void here :)

    - Pete

     
  • Anonymous

    Anonymous - 2009-11-11

    I don't suppose anyone got anywhere with this problem - I am getting the same…

     
  • Anonymous

    Anonymous - 2009-11-11

    Haha, no need to respond to this - it was totally a problem I caused, I was not sending \n to the server - doh!

     

Log in to post a comment.