net/id: handle error case
Juan Batiz-Benet committed
Dec 24, 2014 at 04:22 UTC
99636b571cbfb9c60a0d124214aec41a83b3d3db
1 file changed
+4
-3
net/id.go
+4
-3
@@ -51,10 +51,11 @@ func (ids *IDService) IdentifyConn(c Conn) {
51
if err != nil {
52
log.Error("network: unable to open initial stream for %s", ProtocolIdentify)
53
log.Event(ids.Network.CtxGroup().Context(), "IdentifyOpenFailed", c.RemotePeer())
54
- }
54
+ } else {
55
56
- // ok give the response to our handler.
57
- ids.ResponseHandler(s)
56
+ // ok give the response to our handler.
57
+ ids.ResponseHandler(s)
58
+ }
59
60
ids.currmu.Lock()
61
ch, found := ids.currid[c]