Unverified Commit 4a3fb585 authored by ucwong's avatar ucwong Committed by GitHub

les/fetcher : fix requestTimer leak (#26514)

les/fetcher : fix requestTimer leak
parent 97401b6c
...@@ -272,6 +272,7 @@ func (f *lightFetcher) mainloop() { ...@@ -272,6 +272,7 @@ func (f *lightFetcher) mainloop() {
localHead = f.chain.CurrentHeader() localHead = f.chain.CurrentHeader()
localTd = f.chain.GetTd(localHead.Hash(), localHead.Number.Uint64()) localTd = f.chain.GetTd(localHead.Hash(), localHead.Number.Uint64())
) )
defer requestTimer.Stop()
sub := f.chain.SubscribeChainHeadEvent(headCh) sub := f.chain.SubscribeChainHeadEvent(headCh)
defer sub.Unsubscribe() defer sub.Unsubscribe()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment