diff --git a/pkg/network/tcp_peer.go b/pkg/network/tcp_peer.go index 5b159fda1..a3b1dc45e 100644 --- a/pkg/network/tcp_peer.go +++ b/pkg/network/tcp_peer.go @@ -179,8 +179,8 @@ func (p *TCPPeer) handleConn() { p.incoming <- msg } } - close(p.incoming) p.Disconnect(err) + close(p.incoming) } func (p *TCPPeer) handleIncoming() {