mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-17 18:30:45 +00:00
This commit is contained in:
parent
a1b0d5476d
commit
43b005c479
1 changed files with 7 additions and 4 deletions
|
|
@ -808,10 +808,6 @@ func (pool *LegacyPool) add(tx *types.Transaction, local bool) (replaced bool, e
|
||||||
// already validated by this point
|
// already validated by this point
|
||||||
from, _ := types.Sender(pool.signer, tx)
|
from, _ := types.Sender(pool.signer, tx)
|
||||||
|
|
||||||
if tx.IsSpecialTransaction() && pool.IsSigner(from) && pool.pendingNonces.get(from) == tx.Nonce() {
|
|
||||||
return pool.promoteSpecialTx(from, tx, isLocal)
|
|
||||||
}
|
|
||||||
|
|
||||||
// If the address is not yet known, request exclusivity to track the account
|
// If the address is not yet known, request exclusivity to track the account
|
||||||
// only by this subpool until all transactions are evicted
|
// only by this subpool until all transactions are evicted
|
||||||
var (
|
var (
|
||||||
|
|
@ -834,6 +830,13 @@ func (pool *LegacyPool) add(tx *types.Transaction, local bool) (replaced bool, e
|
||||||
}
|
}
|
||||||
}()
|
}()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Special transactions must also honor the reservation semantics to keep
|
||||||
|
// the coordinator's ownership accounting balanced.
|
||||||
|
if tx.IsSpecialTransaction() && pool.IsSigner(from) && pool.pendingNonces.get(from) == tx.Nonce() {
|
||||||
|
return pool.promoteSpecialTx(from, tx, isLocal)
|
||||||
|
}
|
||||||
|
|
||||||
// If the transaction pool is full, discard underpriced transactions
|
// If the transaction pool is full, discard underpriced transactions
|
||||||
if uint64(pool.all.Slots()+numSlots(tx)) > pool.config.GlobalSlots+pool.config.GlobalQueue {
|
if uint64(pool.all.Slots()+numSlots(tx)) > pool.config.GlobalSlots+pool.config.GlobalQueue {
|
||||||
// If the new transaction is underpriced, don't accept it
|
// If the new transaction is underpriced, don't accept it
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue