Improved handling of client socket disconnection.
Improved handling of client socket disconnections.