diff options
Diffstat (limited to 'ethchain/state_manager.go')
-rw-r--r-- | ethchain/state_manager.go | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/ethchain/state_manager.go b/ethchain/state_manager.go index 36bb14846..a0051181f 100644 --- a/ethchain/state_manager.go +++ b/ethchain/state_manager.go @@ -181,7 +181,6 @@ func (sm *StateManager) ProcessBlock(state *State, parent, block *Block, dontRea coinbase.SetGasPool(block.CalcGasLimit(parent)) // Process the transactions on to current block - //sm.ApplyTransactions(block.Coinbase, state, parent, block.Transactions()) sm.ProcessTransactions(coinbase, state, block, parent, block.Transactions()) // Block validation @@ -197,6 +196,9 @@ func (sm *StateManager) ProcessBlock(state *State, parent, block *Block, dontRea return err } + // Update the state with pending changes + state.Update() + if !block.State().Cmp(state) { return fmt.Errorf("Invalid merkle root.\nrec: %x\nis: %x", block.State().trie.Root, state.trie.Root) } |