From 019edc90357c32b926485b1984357e28aa6b35f2 Mon Sep 17 00:00:00 2001 From: Olaoluwa Osuntokun Date: Mon, 23 Jan 2017 20:33:18 -0800 Subject: [PATCH] peer: display the src peer when logging read error --- peer.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/peer.go b/peer.go index 9e9cf078..098c2ef6 100644 --- a/peer.go +++ b/peer.go @@ -359,7 +359,8 @@ out: for atomic.LoadInt32(&p.disconnect) == 0 { nextMsg, _, err := p.readNextMessage() if err != nil { - peerLog.Infof("unable to read message: %v", err) + peerLog.Infof("unable to read message from %v: %v", + p, err) switch err.(type) { // If this is just a message we don't yet recognize,