peer: close late connections after disconnect
This commit fixes a race condition in btcd's peer networking code. If a peer was told to disconnect before a network socket had been attached, the socket could later be attached but never closed, leaking the connection. The fix adds a lock…
617ebe2bby Boris Nagaev+111−72 files