fixed hanging upon connection