From f6e55962a8cadfb440dd03467017941b96838362 Mon Sep 17 00:00:00 2001 From: obscuren Date: Fri, 14 Nov 2014 13:47:12 +0100 Subject: Fixes for PV41/42 * Don't expand mem on empty value * Removed all coinbase logs for PV42 * Removed C++ bug stuff for LOG* --- chain/block_manager.go | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) (limited to 'chain/block_manager.go') diff --git a/chain/block_manager.go b/chain/block_manager.go index 730a44e7b..d39f188d4 100644 --- a/chain/block_manager.go +++ b/chain/block_manager.go @@ -217,13 +217,13 @@ func (sm *BlockManager) ProcessWithParent(block, parent *Block) (td *big.Int, me txSha := DeriveSha(block.transactions) if bytes.Compare(txSha, block.TxSha) != 0 { - err = fmt.Errorf("Error validating transaction sha. Received %x, got %x", block.TxSha, txSha) + err = fmt.Errorf("Error validating transaction root. Received %x, got %x", block.TxSha, txSha) return } receiptSha := DeriveSha(receipts) if bytes.Compare(receiptSha, block.ReceiptSha) != 0 { - err = fmt.Errorf("Error validating receipt sha. Received %x, got %x", block.ReceiptSha, receiptSha) + err = fmt.Errorf("Error validating receipt root. Received %x, got %x", block.ReceiptSha, receiptSha) return } @@ -238,7 +238,7 @@ func (sm *BlockManager) ProcessWithParent(block, parent *Block) (td *big.Int, me return } - block.SetReceipts(receipts) + block.receipts = receipts rbloom := CreateBloom(block) if bytes.Compare(rbloom, block.LogsBloom) != 0 { err = fmt.Errorf("unable to replicate block's bloom: %x", rbloom) @@ -260,12 +260,7 @@ func (sm *BlockManager) ProcessWithParent(block, parent *Block) (td *big.Int, me messages := state.Manifest().Messages state.Manifest().Reset() - /* - sm.eth.ChainManager().SetTotalDifficulty(td) - sm.eth.ChainManager().add(block) - sm.eth.EventMux().Post(NewBlockEvent{block}) - sm.eth.EventMux().Post(messages) - */ + chainlogger.Infof("Processed block #%d (%x...)\n", block.Number, block.Hash()[0:4]) sm.transState = state.Copy() -- cgit