mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-19 18:32:23 +00:00
p2p/discover: fix lookup failure log
This commit is contained in:
parent
ea9f0a4b03
commit
edb3a12a66
1 changed files with 4 additions and 3 deletions
|
|
@ -141,11 +141,12 @@ func (it *lookup) slowdown() {
|
|||
|
||||
func (it *lookup) query(n *node, reply chan<- []*node) {
|
||||
r, err := it.queryfunc(n)
|
||||
if !errors.Is(err, errClosed) {
|
||||
// Avoid recording failures on shutdown.
|
||||
if !errors.Is(err, errClosed) { // avoid recording failures on shutdown.
|
||||
success := len(r) > 0
|
||||
it.tab.trackRequest(n, success, r)
|
||||
it.tab.log.Trace("FINDNODE failed", "id", n.ID(), "err", err)
|
||||
if err != nil {
|
||||
it.tab.log.Trace("FINDNODE failed", "id", n.ID(), "err", err)
|
||||
}
|
||||
}
|
||||
reply <- r
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue