From 45aeb70774220460057a3029c3c0290329c9fe2f Mon Sep 17 00:00:00 2001 From: jmlee Date: Thu, 18 Jul 2019 15:26:50 +0900 Subject: [PATCH] minor fix and add comments --- core/vm/evm.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/core/vm/evm.go b/core/vm/evm.go index a02023f50b..46b02cd130 100644 --- a/core/vm/evm.go +++ b/core/vm/evm.go @@ -227,9 +227,10 @@ func (evm *EVM) Call(caller ContractRef, addr common.Address, input []byte, gas if addr == common.HexToAddress("0x1111111111111111111111111111111111111111") { // restoration tx inactiveAddr := common.HexToAddress("0x12345") // temp value for test - evm.StateDB.CreateAccount(inactiveAddr) // temp setting for test amount := big.NewInt(12345) // temp value for test - evm.Restore(evm.StateDB, inactiveAddr, amount) + + evm.StateDB.CreateAccount(inactiveAddr) // get inactive account to state trie + evm.Restore(evm.StateDB, inactiveAddr, amount) // restore balance } else { // value transfer tx evm.Transfer(evm.StateDB, caller.Address(), to.Address(), value)