diff options
author | Jeffrey Wilcke <jeffrey@ethereum.org> | 2015-07-04 18:42:13 +0800 |
---|---|---|
committer | Jeffrey Wilcke <jeffrey@ethereum.org> | 2015-07-04 18:42:13 +0800 |
commit | 9c3db1be1dd24c366a58a7ced22adfa0b0839efe (patch) | |
tree | 0c102cd7f590a80bc291b82274e7ca16335a250f /core/block_processor.go | |
parent | 9bb575be7db85f967771018a915fbc4e80345ee2 (diff) | |
parent | 47460b3b4af51e08518c781680897cf2986415cc (diff) | |
download | go-tangerine-9c3db1be1dd24c366a58a7ced22adfa0b0839efe.tar.gz go-tangerine-9c3db1be1dd24c366a58a7ced22adfa0b0839efe.tar.zst go-tangerine-9c3db1be1dd24c366a58a7ced22adfa0b0839efe.zip |
Merge pull request #1369 from obscuren/statedb-update-cleanup
core, core/state: throw out intermediate state
Diffstat (limited to 'core/block_processor.go')
-rw-r--r-- | core/block_processor.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/core/block_processor.go b/core/block_processor.go index e8014ec22..e7ad059c3 100644 --- a/core/block_processor.go +++ b/core/block_processor.go @@ -77,7 +77,7 @@ func (self *BlockProcessor) ApplyTransaction(coinbase *state.StateObject, stated } // Update the state with pending changes - statedb.Update() + statedb.SyncIntermediate() usedGas.Add(usedGas, gas) receipt := types.NewReceipt(statedb.Root().Bytes(), usedGas) @@ -243,7 +243,7 @@ func (sm *BlockProcessor) processWithParent(block, parent *types.Block) (logs st // Commit state objects/accounts to a temporary trie (does not save) // used to calculate the state root. - state.Update() + state.SyncObjects() if header.Root != state.Root() { err = fmt.Errorf("invalid merkle root. received=%x got=%x", header.Root, state.Root()) return |