diff options
author | Jimmy Hu <jimmy.hu@dexon.org> | 2019-03-30 00:38:41 +0800 |
---|---|---|
committer | Wei-Ning Huang <w@dexon.org> | 2019-04-09 21:32:59 +0800 |
commit | b4bb2e15d4b779f3d06eb7f58d848f174926c129 (patch) | |
tree | c6a8f6febca61e7813cb3493149df1d38f2c439c | |
parent | 941ae9567e27edd7ffce3a23be7b5811eab6121d (diff) | |
download | dexon-b4bb2e15d4b779f3d06eb7f58d848f174926c129.tar.gz dexon-b4bb2e15d4b779f3d06eb7f58d848f174926c129.tar.zst dexon-b4bb2e15d4b779f3d06eb7f58d848f174926c129.zip |
dex: fix a panic (#317)
-rw-r--r-- | dex/blockproposer.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/dex/blockproposer.go b/dex/blockproposer.go index 65f9f9e30..846e65617 100644 --- a/dex/blockproposer.go +++ b/dex/blockproposer.go @@ -199,9 +199,9 @@ ListenLoop: select { case ev := <-ch: blocks := blocksToSync(coreHeight, ev.Block.NumberU64()) - b.watchCat.Feed(blocks[len(blocks)-1].Position) if len(blocks) > 0 { + b.watchCat.Feed(blocks[len(blocks)-1].Position) log.Debug("Filling compaction chain", "num", len(blocks), "first", blocks[0].Finalization.Height, "last", blocks[len(blocks)-1].Finalization.Height) |