From 55cbf31f18c35a1fbdd33af99e50498d96de87ab Mon Sep 17 00:00:00 2001 From: irrun Date: Mon, 24 Jun 2024 16:42:17 +0800 Subject: [PATCH] fix: nil pointer when clear simulating bid (#2534) --- miner/bid_simulator.go | 4 ---- 1 file changed, 4 deletions(-) diff --git a/miner/bid_simulator.go b/miner/bid_simulator.go index e80dc90b1..1d77308fe 100644 --- a/miner/bid_simulator.go +++ b/miner/bid_simulator.go @@ -419,10 +419,6 @@ func (b *bidSimulator) clearLoop() { b.bestBidMu.Unlock() b.simBidMu.Lock() - if bid, ok := b.simulatingBid[parentHash]; ok { - bid.env.discard() - } - delete(b.simulatingBid, parentHash) for k, v := range b.simulatingBid { if v.bid.BlockNumber <= blockNumber-core.TriesInMemory { v.env.discard()