diff --git a/core/headerchain.go b/core/headerchain.go index 0bf296ab5c..36b8d68385 100644 --- a/core/headerchain.go +++ b/core/headerchain.go @@ -272,14 +272,12 @@ func (hc *HeaderChain) Append(batch ethdb.Batch, block *types.Block, newInboundE // coincident with a higher order chain. So, this check is skipped for prime // nodes. if nodeCtx > common.PRIME_CTX { - if block.ParentHash() != hc.config.GenesisHash { - manifest := rawdb.ReadManifest(hc.headerDb, block.ParentHash()) - if manifest == nil { - return errors.New("manifest not found for parent") - } - if block.ManifestHash(nodeCtx) != types.DeriveSha(manifest, trie.NewStackTrie(nil)) { - return errors.New("manifest does not match hash") - } + manifest := rawdb.ReadManifest(hc.headerDb, block.ParentHash()) + if manifest == nil { + return errors.New("manifest not found for parent") + } + if block.ManifestHash(nodeCtx) != types.DeriveSha(manifest, trie.NewStackTrie(nil)) { + return errors.New("manifest does not match hash") } } elapsedCollectBlockManifest := common.PrettyDuration(time.Since(collectBlockManifest)) diff --git a/core/slice.go b/core/slice.go index ca42481655..5f74cc04c8 100644 --- a/core/slice.go +++ b/core/slice.go @@ -645,6 +645,7 @@ func (sl *Slice) init(genesis *Genesis) error { // Initialize slice state for genesis knot genesisTermini := []common.Hash{genesisHash, genesisHash, genesisHash, genesisHash} rawdb.WriteTermini(sl.sliceDb, genesisHash, genesisTermini) + rawdb.WriteManifest(sl.sliceDb, genesisHash, types.BlockManifest{genesisHash}) // Append each of the knot blocks sl.bestPhKey = genesisHash