From 99636b571cbfb9c60a0d124214aec41a83b3d3db Mon Sep 17 00:00:00 2001 From: Juan Batiz-Benet Date: Wed, 24 Dec 2014 04:22:51 -0800 Subject: [PATCH] net/id: handle error case --- net/id.go | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/net/id.go b/net/id.go index 92a3b684d..802d54794 100644 --- a/net/id.go +++ b/net/id.go @@ -51,10 +51,11 @@ func (ids *IDService) IdentifyConn(c Conn) { if err != nil { log.Error("network: unable to open initial stream for %s", ProtocolIdentify) log.Event(ids.Network.CtxGroup().Context(), "IdentifyOpenFailed", c.RemotePeer()) - } + } else { - // ok give the response to our handler. - ids.ResponseHandler(s) + // ok give the response to our handler. + ids.ResponseHandler(s) + } ids.currmu.Lock() ch, found := ids.currid[c]