mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-27 15:16:43 +00:00
keep gp to call always max
This commit is contained in:
parent
af4a29d20a
commit
5db5e5d817
1 changed files with 1 additions and 6 deletions
|
|
@ -1352,12 +1352,7 @@ func doCall(ctx context.Context, b Backend, args TransactionArgs, state *state.S
|
||||||
// Make sure the context is cancelled when the call has completed
|
// Make sure the context is cancelled when the call has completed
|
||||||
// this makes sure resources are cleaned up.
|
// this makes sure resources are cleaned up.
|
||||||
defer cancel()
|
defer cancel()
|
||||||
gp := new(core.GasPool)
|
gp := new(core.GasPool).AddGas(math.MaxUint64)
|
||||||
if globalGasCap == 0 {
|
|
||||||
gp.AddGas(math.MaxUint64)
|
|
||||||
} else {
|
|
||||||
gp.AddGas(globalGasCap)
|
|
||||||
}
|
|
||||||
return applyMessage(ctx, b, args, state, header, timeout, gp, &blockCtx, &vm.Config{NoBaseFee: true}, precompiles, true)
|
return applyMessage(ctx, b, args, state, header, timeout, gp, &blockCtx, &vm.Config{NoBaseFee: true}, precompiles, true)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue