mirror of
https://github.com/ipfs/kubo.git
synced 2025-07-01 10:49:24 +08:00
net/id: handle error case
This commit is contained in:
@ -51,10 +51,11 @@ func (ids *IDService) IdentifyConn(c Conn) {
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
log.Error("network: unable to open initial stream for %s", ProtocolIdentify)
|
log.Error("network: unable to open initial stream for %s", ProtocolIdentify)
|
||||||
log.Event(ids.Network.CtxGroup().Context(), "IdentifyOpenFailed", c.RemotePeer())
|
log.Event(ids.Network.CtxGroup().Context(), "IdentifyOpenFailed", c.RemotePeer())
|
||||||
}
|
} else {
|
||||||
|
|
||||||
// ok give the response to our handler.
|
// ok give the response to our handler.
|
||||||
ids.ResponseHandler(s)
|
ids.ResponseHandler(s)
|
||||||
|
}
|
||||||
|
|
||||||
ids.currmu.Lock()
|
ids.currmu.Lock()
|
||||||
ch, found := ids.currid[c]
|
ch, found := ids.currid[c]
|
||||||
|
Reference in New Issue
Block a user