sock.close unless @keepalive