Browse Source

Fixing blockcing nil pointer

pull/262/head
Sarah Jamie Lewis 4 months ago
parent
commit
f08af1289f
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      protocol/connections/engine.go

+ 1
- 1
protocol/connections/engine.go View File

@@ -122,7 +122,7 @@ func (e *engine) eventHandler() {
case event.BlockPeer:
e.blocked.Store(ev.Data[event.RemotePeer], true)
connection, err := e.service.GetConnection(ev.Data[event.RemotePeer])
if err != nil {
if connection != nil && err == nil {
connection.Close()
}
case event.ProtocolEngineStartListen:

Loading…
Cancel
Save