Skip to content

Commit 1a6ef5a

Browse files
ywzqwwtholiman
authored andcommitted
core/blockchain: remove block from futureBlocks on error (#19763)
1 parent ad03d98 commit 1a6ef5a

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

core/blockchain.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1549,6 +1549,7 @@ func (bc *BlockChain) insertChain(chain types.Blocks, verifySeals bool) (int, []
15491549

15501550
// Some other error occurred, abort
15511551
case err != nil:
1552+
bc.futureBlocks.Remove(block.Hash())
15521553
stats.ignored += len(it.chain)
15531554
bc.reportBlock(block, nil, err)
15541555
return it.index, events, coalescedLogs, err

0 commit comments

Comments
 (0)