diff --git a/p2p/peer.go b/p2p/peer.go index 238d3d9c9..893ba86d7 100644 --- a/p2p/peer.go +++ b/p2p/peer.go @@ -97,6 +97,7 @@ func NewPeer(id ClientIdentity, caps []Cap) *Peer { conn, _ := net.Pipe() peer := newPeer(conn, nil, nil) peer.setHandshakeInfo(id, nil, caps) + close(peer.closed) return peer }