Unverified Commit bd566977 authored by gary rong's avatar gary rong Committed by GitHub

core: fix bad parent hash when jumping to genesis in setHead (#23162)

parent 99169016
...@@ -574,7 +574,7 @@ func (hc *HeaderChain) SetHead(head uint64, updateFn UpdateHeadBlocksCallback, d ...@@ -574,7 +574,7 @@ func (hc *HeaderChain) SetHead(head uint64, updateFn UpdateHeadBlocksCallback, d
if parent == nil { if parent == nil {
parent = hc.genesisHeader parent = hc.genesisHeader
} }
parentHash = hdr.ParentHash parentHash = parent.Hash()
// Notably, since geth has the possibility for setting the head to a low // Notably, since geth has the possibility for setting the head to a low
// height which is even lower than ancient head. // height which is even lower than ancient head.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment