mirror of
https://github.com/kaspanet/kaspad.git
synced 2025-03-30 15:08:33 +00:00
[NOD-704] Call dag.IsInSelectedParentChain in every iteration of dag.SelectedParentChain (#606)
This commit is contained in:
parent
11de12304e
commit
bf36f9ceb6
@ -1517,6 +1517,11 @@ func (dag *BlockDAG) SelectedParentChain(blockHash *daghash.Hash) ([]*daghash.Ha
|
||||
|
||||
node := dag.index.LookupNode(blockHash)
|
||||
blockHash = node.selectedParent.hash
|
||||
|
||||
isBlockInSelectedParentChain, err = dag.IsInSelectedParentChain(blockHash)
|
||||
if err != nil {
|
||||
return nil, nil, err
|
||||
}
|
||||
}
|
||||
|
||||
// Find the index of the blockHash in the selectedParentChainSlice
|
||||
|
Loading…
x
Reference in New Issue
Block a user