diff options
author | obscuren <geffobscura@gmail.com> | 2015-06-17 16:20:33 +0800 |
---|---|---|
committer | obscuren <geffobscura@gmail.com> | 2015-06-17 16:20:33 +0800 |
commit | 5721fcf668f8ab798b6602dc6ff88726bf0c8f86 (patch) | |
tree | 5ba543be4de8caca8950ae09f4fb28c1eb45be91 /core/vm | |
parent | dfd18d245af37344f8e6fadca55f22a639d7f1ba (diff) | |
download | dexon-5721fcf668f8ab798b6602dc6ff88726bf0c8f86.tar.gz dexon-5721fcf668f8ab798b6602dc6ff88726bf0c8f86.tar.zst dexon-5721fcf668f8ab798b6602dc6ff88726bf0c8f86.zip |
core/state, core/vm: cleanup refunds
Diffstat (limited to 'core/vm')
-rw-r--r-- | core/vm/vm.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/core/vm/vm.go b/core/vm/vm.go index c5ad761f6..0486fbbc7 100644 --- a/core/vm/vm.go +++ b/core/vm/vm.go @@ -690,7 +690,7 @@ func (self *Vm) calculateGasAndSize(context *Context, caller ContextRef, op OpCo // 0 => non 0 g = params.SstoreSetGas } else if len(val) > 0 && len(y.Bytes()) == 0 { - statedb.Refund(self.env.Origin(), params.SstoreRefundGas) + statedb.Refund(params.SstoreRefundGas) g = params.SstoreClearGas } else { @@ -700,7 +700,7 @@ func (self *Vm) calculateGasAndSize(context *Context, caller ContextRef, op OpCo gas.Set(g) case SUICIDE: if !statedb.IsDeleted(context.Address()) { - statedb.Refund(self.env.Origin(), params.SuicideRefundGas) + statedb.Refund(params.SuicideRefundGas) } case MLOAD: newMemSize = calcMemSize(stack.peek(), u256(32)) |