p2p: don't discard reason set by Disconnect (#16559)

Peer.run was discarding the reason for disconnection sent to the disc
channel by Disconnect.
This commit is contained in:
Guilherme Salgado 2018-05-09 00:20:20 +01:00 committed by Kiel barry
parent 9620de7ee9
commit 4cfe9aaa81

View file

@ -220,6 +220,7 @@ loop:
reason = discReasonForError(err)
break loop
case err = <-p.disc:
reason = discReasonForError(err)
break loop
}
}