p2p/discover: fix goroutine leak due to blocking on sync.Once
This commit is contained in:
@ -335,7 +335,7 @@ func (tab *Table) ping(id NodeID, addr *net.UDPAddr) error {
|
||||
}
|
||||
// Pong received, update the database and return
|
||||
tab.db.updateLastPong(id, time.Now())
|
||||
go tab.db.expirer()
|
||||
tab.db.ensureExpirer()
|
||||
|
||||
return nil
|
||||
}
|
||||
|
Reference in New Issue
Block a user