eof for socket block script
eof and eof? run awhile
Is it OK ?
How to check socket EOF without blocking ?
Updated by akr (Akira Tanaka) over 11 years ago
- Status changed from Feedback to Rejected
I found server and client code in redmine.
You cannot check EOF until server close the socket or send some data.
Your server, test_tcp_server.rb, doesn't close the socket until the client closes the socket.
The server never send data.
So eof? need to block because the server may close the socket in future.
It is not a bug.