diff --git a/src/yggdrasil/search.go b/src/yggdrasil/search.go index 4b9cd03..d9dc76e 100644 --- a/src/yggdrasil/search.go +++ b/src/yggdrasil/search.go @@ -107,7 +107,10 @@ func (s *searches) doSearchStep(sinfo *searchInfo) { // Send to the next search target var next *dhtInfo next, sinfo.toVisit = sinfo.toVisit[0], sinfo.toVisit[1:] + var oldPings int + oldPings, next.pings = next.pings, 0 s.core.dht.ping(next, &sinfo.dest) + next.pings = oldPings // Don't evict a node for searching with it too much sinfo.visited[*next.getNodeID()] = true } }