aboutsummaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
authorobscuren <geffobscura@gmail.com>2015-04-04 18:40:48 +0800
committerobscuren <geffobscura@gmail.com>2015-04-04 18:40:48 +0800
commit218bfeb60e9a9e7f0874db18135e7ad633ff83f1 (patch)
tree712af802e23806ab04a8c4a3c615a50823c4d8e4 /core
parenta0e44e3281fcef0913b172ed4cdb5283a8d4a46b (diff)
downloaddexon-218bfeb60e9a9e7f0874db18135e7ad633ff83f1.tar
dexon-218bfeb60e9a9e7f0874db18135e7ad633ff83f1.tar.gz
dexon-218bfeb60e9a9e7f0874db18135e7ad633ff83f1.tar.bz2
dexon-218bfeb60e9a9e7f0874db18135e7ad633ff83f1.tar.lz
dexon-218bfeb60e9a9e7f0874db18135e7ad633ff83f1.tar.xz
dexon-218bfeb60e9a9e7f0874db18135e7ad633ff83f1.tar.zst
dexon-218bfeb60e9a9e7f0874db18135e7ad633ff83f1.zip
check for nil block (tmp).
@zelig this needs to be addressed in the block pool.
Diffstat (limited to 'core')
-rw-r--r--core/chain_manager.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/core/chain_manager.go b/core/chain_manager.go
index b9a08b13d..3dcee6a93 100644
--- a/core/chain_manager.go
+++ b/core/chain_manager.go
@@ -440,6 +440,9 @@ func (self *ChainManager) InsertChain(chain types.Blocks) error {
var queue = make([]interface{}, len(chain))
var queueEvent = queueEvent{queue: queue}
for i, block := range chain {
+ if block == nil {
+ continue
+ }
// Call in to the block processor and check for errors. It's likely that if one block fails
// all others will fail too (unless a known block is returned).
td, logs, err := self.processor.Process(block)