Merge 36c83b40bd into merged_master (Bitcoin PR bitcoin/bitcoin#25023)

This commit is contained in:
Byron Hambly 2024-10-25 11:11:26 +02:00
commit 8e5b356a85
5 changed files with 15 additions and 16 deletions

View file

@ -23,11 +23,9 @@ std::string CBlockIndex::ToString() const
pprev, nHeight, hashMerkleRoot.ToString(), GetBlockHash().ToString());
}
void CChain::SetTip(CBlockIndex *pindex) {
if (pindex == nullptr) {
vChain.clear();
return;
}
void CChain::SetTip(CBlockIndex& block)
{
CBlockIndex* pindex = █
vChain.resize(pindex->nHeight + 1);
while (pindex && vChain[pindex->nHeight] != pindex) {
vChain[pindex->nHeight] = pindex;