From f8601430fddfe44b9c1781957ab13578cf17ad9f Mon Sep 17 00:00:00 2001 From: cui <523516579@qq.com> Date: Sat, 3 Mar 2018 18:09:36 +0800 Subject: core: should enqueue the invalids tx anyway even the pending is empty we shoud enqueue the invalid txs --- core/tx_pool.go | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/core/tx_pool.go b/core/tx_pool.go index 0534fe57a..7d7ed334a 100644 --- a/core/tx_pool.go +++ b/core/tx_pool.go @@ -881,12 +881,13 @@ func (pool *TxPool) removeTx(hash common.Hash) { if pending.Empty() { delete(pool.pending, addr) delete(pool.beats, addr) - } else { - // Otherwise postpone any invalidated transactions - for _, tx := range invalids { - pool.enqueueTx(tx.Hash(), tx) - } } + + // Otherwise postpone any invalidated transactions + for _, tx := range invalids { + pool.enqueueTx(tx.Hash(), tx) + } + // Update the account nonce if needed if nonce := tx.Nonce(); pool.pendingState.GetNonce(addr) > nonce { pool.pendingState.SetNonce(addr, nonce) -- cgit v1.2.3