mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-02-26 15:47:21 +00:00
les/fetcher : fix requestTimer leak (#26514)
les/fetcher : fix requestTimer leak
This commit is contained in:
parent
97401b6c63
commit
4a3fb585dd
1 changed files with 1 additions and 0 deletions
|
|
@ -272,6 +272,7 @@ func (f *lightFetcher) mainloop() {
|
|||
localHead = f.chain.CurrentHeader()
|
||||
localTd = f.chain.GetTd(localHead.Hash(), localHead.Number.Uint64())
|
||||
)
|
||||
defer requestTimer.Stop()
|
||||
sub := f.chain.SubscribeChainHeadEvent(headCh)
|
||||
defer sub.Unsubscribe()
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue