File tree Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -3773,7 +3773,9 @@ bool BlockManager::LoadBlockIndex(
3773
3773
pindex->nStatus |= BLOCK_FAILED_CHILD;
3774
3774
setDirtyBlockIndex.insert (pindex);
3775
3775
}
3776
- if (pindex->IsValid (BLOCK_VALID_TRANSACTIONS) && (pindex->HaveTxsDownloaded () || pindex->pprev == nullptr )) {
3776
+ if (pindex->IsAssumedValid () ||
3777
+ (pindex->IsValid (BLOCK_VALID_TRANSACTIONS) &&
3778
+ (pindex->HaveTxsDownloaded () || pindex->pprev == nullptr ))) {
3777
3779
block_index_candidates.insert (pindex);
3778
3780
}
3779
3781
if (pindex->nStatus & BLOCK_FAILED_MASK && (!pindexBestInvalid || pindex->nChainWork > pindexBestInvalid->nChainWork ))
Original file line number Diff line number Diff line change @@ -647,9 +647,10 @@ class CChainState
647
647
const std::optional<uint256> m_from_snapshot_blockhash;
648
648
649
649
/* *
650
- * The set of all CBlockIndex entries with BLOCK_VALID_TRANSACTIONS (for itself and all ancestors) and
651
- * as good as our current tip or better. Entries may be failed, though, and pruning nodes may be
652
- * missing the data for the block.
650
+ * The set of all CBlockIndex entries with either BLOCK_VALID_TRANSACTIONS (for
651
+ * itself and all ancestors) *or* BLOCK_ASSUMED_VALID (if using background
652
+ * chainstates) and as good as our current tip or better. Entries may be failed,
653
+ * though, and pruning nodes may be missing the data for the block.
653
654
*/
654
655
std::set<CBlockIndex*, CBlockIndexWorkComparator> setBlockIndexCandidates;
655
656
You can’t perform that action at this time.
0 commit comments