diff --git a/core/tx_list.go b/core/tx_list.go index fea4434b9b..1540e042da 100644 --- a/core/tx_list.go +++ b/core/tx_list.go @@ -512,7 +512,9 @@ func (l *txList) Filter(costLimit *uint256.Int, gasLimit uint64) (types.Transact } invalids = l.txs.filter(func(tx *types.Transaction) bool { return tx.Nonce() > lowest }) } + l.txs.reheap() + return removed, invalids } diff --git a/eth/fetcher/tx_fetcher.go b/eth/fetcher/tx_fetcher.go index c147b7c50a..81f28d66d3 100644 --- a/eth/fetcher/tx_fetcher.go +++ b/eth/fetcher/tx_fetcher.go @@ -719,9 +719,10 @@ func (f *TxFetcher) rescheduleWait(timer *mclock.Timer, trigger chan struct{}) { } } } - *timer = f.clock.AfterFunc(f.txArrivalWait-time.Duration(now-earliest), func() { - trigger <- struct{}{} - }) + *timer = f.clock.AfterFunc( + f.txArrivalWait-time.Duration(now-earliest), + func() { trigger <- struct{}{} }, + ) } // rescheduleTimeout iterates over all the transactions currently in flight and