fix contract call in gst and executor.nim
This commit is contained in:
parent
8b3b1f4c57
commit
5ba44083f0
|
@ -27,7 +27,7 @@ proc contractCall(t: Transaction, vmState: BaseVMState, sender: EthAddress, fork
|
|||
if execComputation(computation):
|
||||
let
|
||||
gasRemaining = computation.gasMeter.gasRemaining.u256
|
||||
gasRefunded = computation.gasMeter.gasRefunded.u256
|
||||
gasRefunded = computation.getGasRefund().u256
|
||||
gasUsed = t.gasLimit.u256 - gasRemaining
|
||||
gasRefund = min(gasRefunded, gasUsed div 2)
|
||||
gasRefundAmount = (gasRefund + gasRemaining) * t.gasPrice.u256
|
||||
|
|
|
@ -73,7 +73,7 @@ proc testFixtureIndexes(prevStateRoot: Hash256, header: BlockHeader, pre: JsonNo
|
|||
if execComputation(computation):
|
||||
let
|
||||
gasRemaining = computation.gasMeter.gasRemaining.u256
|
||||
gasRefunded = computation.gasMeter.gasRefunded.u256
|
||||
gasRefunded = computation.getGasRefund().u256
|
||||
gasUsed = transaction.gasLimit.u256 - gasRemaining
|
||||
gasRefund = min(gasRefunded, gasUsed div 2)
|
||||
gasRefundAmount = (gasRefund + gasRemaining) * transaction.gasPrice.u256
|
||||
|
|
Loading…
Reference in New Issue