From 8d62ee65b2d3100da0292232f8169282237f5487 Mon Sep 17 00:00:00 2001 From: gary rong Date: Sat, 16 Jan 2021 06:04:38 +0800 Subject: [PATCH] les: don't drop sentTo for normal cases (#22048) --- les/retrieve.go | 5 ----- 1 file changed, 5 deletions(-) diff --git a/les/retrieve.go b/les/retrieve.go index ca4f867ea8..3174d49878 100644 --- a/les/retrieve.go +++ b/les/retrieve.go @@ -337,7 +337,6 @@ func (r *sentReq) tryRequest() { } defer func() { - // send feedback to server pool and remove peer if hard timeout happened pp, ok := p.(*serverPeer) if hrto && ok { pp.Log().Debug("Request timed out hard") @@ -345,10 +344,6 @@ func (r *sentReq) tryRequest() { r.rm.peers.unregister(pp.id) } } - - r.lock.Lock() - delete(r.sentTo, p) - r.lock.Unlock() }() select {