aboutsummaryrefslogtreecommitdiffstats
path: root/consensus
diff options
context:
space:
mode:
Diffstat (limited to 'consensus')
-rw-r--r--consensus/ethash/consensus.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/consensus/ethash/consensus.go b/consensus/ethash/consensus.go
index fb9a396ae..4d909146f 100644
--- a/consensus/ethash/consensus.go
+++ b/consensus/ethash/consensus.go
@@ -191,6 +191,9 @@ func (ethash *Ethash) VerifyUncles(chain consensus.ChainReader, block *types.Blo
if len(block.Uncles()) > maxUncles {
return errTooManyUncles
}
+ if len(block.Uncles()) == 0 {
+ return nil
+ }
// Gather the set of past uncles and ancestors
uncles, ancestors := mapset.NewSet(), make(map[common.Hash]*types.Header)