Skip to content

Commit

Permalink
fix: nil pointer when clear simulating bid (bnb-chain#2534)
Browse files Browse the repository at this point in the history
  • Loading branch information
irrun authored and jellyb0y committed Aug 11, 2024
1 parent 31e6d31 commit 0d85683
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions miner/bid_simulator.go
Original file line number Diff line number Diff line change
Expand Up @@ -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()
Expand Down

0 comments on commit 0d85683

Please sign in to comment.