aboutsummaryrefslogtreecommitdiffstats
path: root/cmd/utils/flags.go
diff options
context:
space:
mode:
authorPéter Szilágyi <peterke@gmail.com>2019-04-08 21:16:05 +0800
committerGitHub <noreply@github.com>2019-04-08 21:16:05 +0800
commit4e13a09c5033b4cf073db6aeaaa7d159dcf07f30 (patch)
tree0f64daac335200ce6fd45d6ee9f62dabc0fb1887 /cmd/utils/flags.go
parentc942700427557e3ff6de3aaf6b916e2f056c1ec2 (diff)
parent009d2fe2d650b1a92e28f0decbf5f7fa628779e9 (diff)
downloadgo-tangerine-4e13a09c5033b4cf073db6aeaaa7d159dcf07f30.tar.gz
go-tangerine-4e13a09c5033b4cf073db6aeaaa7d159dcf07f30.tar.zst
go-tangerine-4e13a09c5033b4cf073db6aeaaa7d159dcf07f30.zip
Merge pull request #19370 from karalabe/geth-1.8.24v1.8.24
Backport PR for the v1.8.24 maintenance release
Diffstat (limited to 'cmd/utils/flags.go')
-rw-r--r--cmd/utils/flags.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/cmd/utils/flags.go b/cmd/utils/flags.go
index 55e84b876..052660ba1 100644
--- a/cmd/utils/flags.go
+++ b/cmd/utils/flags.go
@@ -411,6 +411,10 @@ var (
Name: "vmdebug",
Usage: "Record information useful for VM and contract debugging",
}
+ RPCGlobalGasCap = cli.Uint64Flag{
+ Name: "rpc.gascap",
+ Usage: "Sets a cap on gas that can be used in eth_call/estimateGas",
+ }
// Logging and debug settings
EthStatsURLFlag = cli.StringFlag{
Name: "ethstats",
@@ -1256,6 +1260,9 @@ func SetEthConfig(ctx *cli.Context, stack *node.Node, cfg *eth.Config) {
if ctx.GlobalIsSet(EVMInterpreterFlag.Name) {
cfg.EVMInterpreter = ctx.GlobalString(EVMInterpreterFlag.Name)
}
+ if ctx.GlobalIsSet(RPCGlobalGasCap.Name) {
+ cfg.RPCGasCap = new(big.Int).SetUint64(ctx.GlobalUint64(RPCGlobalGasCap.Name))
+ }
// Override any default configs for hard coded networks.
switch {