mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-06-08 07:58:40 +00:00
core: txpool fix
This commit is contained in:
parent
e079c9353a
commit
9d545adcb3
1 changed files with 0 additions and 8 deletions
|
|
@ -130,14 +130,6 @@ func ValidateTransaction(tx *types.Transaction, head *types.Header, signer types
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
if gasCostPerStateByte != 0 {
|
|
||||||
// We require transactions to pay for 110% of intrinsic gas in order to
|
|
||||||
// prevent situations where a change in gas limit invalidates a lot
|
|
||||||
// of transactions in the txpool
|
|
||||||
if minGas := (intrGas.RegularGas * 10) / 9; tx.Gas() < minGas {
|
|
||||||
return fmt.Errorf("%w: gas %v, minimum needed %v", core.ErrIntrinsicGas, tx.Gas(), minGas)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if tx.Gas() < intrGas.RegularGas {
|
if tx.Gas() < intrGas.RegularGas {
|
||||||
return fmt.Errorf("%w: gas %v, minimum needed %v", core.ErrIntrinsicGas, tx.Gas(), intrGas.RegularGas)
|
return fmt.Errorf("%w: gas %v, minimum needed %v", core.ErrIntrinsicGas, tx.Gas(), intrGas.RegularGas)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue