We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c974722 commit 69422b9Copy full SHA for 69422b9
1 file changed
core/state/state_sizer.go
@@ -346,7 +346,7 @@ func (t *SizeTracker) run() {
346
347
// Evict the stale statistics
348
heap.Push(&h, stats[u.root])
349
- for u.blockNumber-h[0].BlockNumber > statEvictThreshold {
+ for len(h) > 0 && u.blockNumber-h[0].BlockNumber > statEvictThreshold {
350
delete(stats, h[0].StateRoot)
351
heap.Pop(&h)
352
}
0 commit comments