Check if the client's stderr was closed.
Correctly set non-blocking flag.