Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
新注册的用户请输入邮箱并保存,随后登录邮箱激活账号。后续可直接使用邮箱登录!
Open sidebar
bao xinyu
vm-native
Commits
98c4f732
Commit
98c4f732
authored
Dec 22, 2022
by
志宏 蔡
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: resolve the nil pointer for enable_optimize_charge_gas. --bug=1004768
parent
f02a1b84
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
chainconfigmgr/chain_config_contract.go
chainconfigmgr/chain_config_contract.go
+1
-1
No files found.
chainconfigmgr/chain_config_contract.go
View file @
98c4f732
...
...
@@ -346,7 +346,7 @@ func (r *ChainCoreRuntime) CoreUpdate(txSimContext protocol.TxSimContext, params
}
if
enableOptimizeChargeGas
,
ok
:=
params
[
paramNameEnableOptimizeChargeGas
];
ok
{
if
!
chainConfig
.
AccountConfig
.
EnableGas
{
if
chainConfig
.
AccountConfig
==
nil
||
!
chainConfig
.
AccountConfig
.
EnableGas
{
return
nil
,
errors
.
New
(
"can not set `enable_optimize_charge_gas` flag when `enable_gas` is disabled"
)
}
parseBool
,
_
:=
strconv
.
ParseBool
(
string
(
enableOptimizeChargeGas
))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment