in reply to Low level socket question.

Don't know if this will help but, you could check the $! after the recv call.