Parcourir la source

core: fix txpool off-by-one error (#21683)

Martin Holst Swende il y a 5 ans
Parent
commit
706f5e3b98
1 fichiers modifiés avec 1 ajouts et 0 suppressions
  1. 1 0
      core/tx_pool.go

+ 1 - 0
core/tx_pool.go

@@ -817,6 +817,7 @@ func (pool *TxPool) addTxs(txs []*types.Transaction, local, sync bool) []error {
 			nilSlot++
 		}
 		errs[nilSlot] = err
+		nilSlot++
 	}
 	// Reorg the pool internals if needed and return
 	done := pool.requestPromoteExecutables(dirtyAddrs)