fixed server crashing when reading from a disconnected client