mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-20 10:52:25 +00:00
Revert "core: remove pointless check for excessBlobGas nilness (#27797)"
This reverts commit cd2e754633.
This commit is contained in:
parent
562be5a6f8
commit
116216055f
1 changed files with 4 additions and 0 deletions
|
|
@ -242,6 +242,10 @@ func (st *StateTransition) buyGas() error {
|
||||||
}
|
}
|
||||||
if st.evm.ChainConfig().IsCancun(st.evm.Context.BlockNumber, st.evm.Context.Time) {
|
if st.evm.ChainConfig().IsCancun(st.evm.Context.BlockNumber, st.evm.Context.Time) {
|
||||||
if blobGas := st.blobGasUsed(); blobGas > 0 {
|
if blobGas := st.blobGasUsed(); blobGas > 0 {
|
||||||
|
if st.evm.Context.ExcessBlobGas == nil {
|
||||||
|
// programming error
|
||||||
|
panic("missing field excess data gas")
|
||||||
|
}
|
||||||
// Check that the user has enough funds to cover blobGasUsed * tx.BlobGasFeeCap
|
// Check that the user has enough funds to cover blobGasUsed * tx.BlobGasFeeCap
|
||||||
blobBalanceCheck := new(big.Int).SetUint64(blobGas)
|
blobBalanceCheck := new(big.Int).SetUint64(blobGas)
|
||||||
blobBalanceCheck.Mul(blobBalanceCheck, st.msg.BlobGasFeeCap)
|
blobBalanceCheck.Mul(blobBalanceCheck, st.msg.BlobGasFeeCap)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue