aboutsummaryrefslogtreecommitdiffstats
path: root/ethchain/block.go
diff options
context:
space:
mode:
Diffstat (limited to 'ethchain/block.go')
-rw-r--r--ethchain/block.go5
1 files changed, 3 insertions, 2 deletions
diff --git a/ethchain/block.go b/ethchain/block.go
index 7ad9984be..472ae134a 100644
--- a/ethchain/block.go
+++ b/ethchain/block.go
@@ -221,8 +221,9 @@ func (block *Block) Undo() {
func (block *Block) MakeContract(tx *Transaction) {
contract := MakeContract(tx, NewState(block.state))
-
- block.contractStates[string(tx.Hash()[12:])] = contract.state
+ if contract != nil {
+ block.contractStates[string(tx.Hash()[12:])] = contract.state
+ }
}
/////// Block Encoding