aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbojie <bojie@dexon.org>2019-02-23 15:35:56 +0800
committerWei-Ning Huang <w@dexon.org>2019-04-09 13:50:02 +0800
commit790b372bf14a09a93b29324e445d5afe086ea843 (patch)
tree52b58fae4bcea192c2fbbda4b79c4395b5492962
parent83c15169a8da268ae0989a52c8e4c663519d0a79 (diff)
downloaddexon-790b372bf14a09a93b29324e445d5afe086ea843.tar.gz
dexon-790b372bf14a09a93b29324e445d5afe086ea843.tar.zst
dexon-790b372bf14a09a93b29324e445d5afe086ea843.zip
fee: fix wrong gas used (#208)
-rw-r--r--core/state_transition.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/core/state_transition.go b/core/state_transition.go
index ce05e54a2..02d58575b 100644
--- a/core/state_transition.go
+++ b/core/state_transition.go
@@ -242,6 +242,8 @@ func (st *StateTransition) dexonRefundGas() {
refund = st.state.GetRefund()
}
+ st.gas = refund
+
// Return ETH for remaining gas, exchanged at the original rate.
remaining := new(big.Int).Mul(new(big.Int).SetUint64(refund), st.gasPrice)
st.state.AddBalance(st.msg.From(), remaining)