Fix bug when client close connection

when client close  connection initiative, server should free client as well. Or fd may be exhausted, as we connect and close frequently.