diff options
author | Martin Holst Swende <martin@swende.se> | 2017-09-04 16:56:45 +0800 |
---|---|---|
committer | Felix Lange <fjl@users.noreply.github.com> | 2017-09-04 16:56:45 +0800 |
commit | 23b51a68cbdd637824be906c9354a0b59c57491b (patch) | |
tree | d7f182bdf8b93e90f526637991f3490d12e9a654 /core/vm/gas_table.go | |
parent | dc92779c0a1e01de9561087a3a534d9d7cfdef3f (diff) | |
download | dexon-23b51a68cbdd637824be906c9354a0b59c57491b.tar dexon-23b51a68cbdd637824be906c9354a0b59c57491b.tar.gz dexon-23b51a68cbdd637824be906c9354a0b59c57491b.tar.bz2 dexon-23b51a68cbdd637824be906c9354a0b59c57491b.tar.lz dexon-23b51a68cbdd637824be906c9354a0b59c57491b.tar.xz dexon-23b51a68cbdd637824be906c9354a0b59c57491b.tar.zst dexon-23b51a68cbdd637824be906c9354a0b59c57491b.zip |
core/vm: avoid state lookup during gas calc for call (#15061)
Diffstat (limited to 'core/vm/gas_table.go')
-rw-r--r-- | core/vm/gas_table.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/vm/gas_table.go b/core/vm/gas_table.go index 3b0698ce9..13712295c 100644 --- a/core/vm/gas_table.go +++ b/core/vm/gas_table.go @@ -324,7 +324,7 @@ func gasCall(gt params.GasTable, evm *EVM, contract *Contract, stack *Stack, mem eip158 = evm.ChainConfig().IsEIP158(evm.BlockNumber) ) if eip158 { - if evm.StateDB.Empty(address) && transfersValue { + if transfersValue && evm.StateDB.Empty(address) { gas += params.CallNewAccountGas } } else if !evm.StateDB.Exist(address) { |