mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-17 02:10:46 +00:00
Merge pull request #728 from gzliudan/fix-pend-tx
core/txpool: fix very high pending special transactions
This commit is contained in:
commit
cb2d604786
2 changed files with 2 additions and 2 deletions
|
|
@ -570,7 +570,7 @@ func (pool *TxPool) Pending(enforceTips bool) map[common.Address]types.Transacti
|
||||||
// If the miner requests tip enforcement, cap the lists now
|
// If the miner requests tip enforcement, cap the lists now
|
||||||
if enforceTips && !pool.locals.contains(addr) {
|
if enforceTips && !pool.locals.contains(addr) {
|
||||||
for i, tx := range txs {
|
for i, tx := range txs {
|
||||||
if tx.EffectiveGasTipIntCmp(pool.gasPrice, pool.priced.urgent.baseFee) < 0 {
|
if !tx.IsSpecialTransaction() && tx.EffectiveGasTipIntCmp(pool.gasPrice, pool.priced.urgent.baseFee) < 0 {
|
||||||
txs = txs[:i]
|
txs = txs[:i]
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -481,7 +481,7 @@ func (tx *Transaction) TxCost(number *big.Int) *big.Int {
|
||||||
|
|
||||||
func (tx *Transaction) IsSpecialTransaction() bool {
|
func (tx *Transaction) IsSpecialTransaction() bool {
|
||||||
to := tx.To()
|
to := tx.To()
|
||||||
return to != nil && (*to == common.RandomizeSMCBinary || *to == common.BlockSignersBinary)
|
return to != nil && (*to == common.BlockSignersBinary || *to == common.RandomizeSMCBinary)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (tx *Transaction) IsTradingTransaction() bool {
|
func (tx *Transaction) IsTradingTransaction() bool {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue