mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-02-10 15:41:21 +00:00
fix InvalidateBlock to repopulate setBlockIndexCandidates
Rebased-From: a9af415887f03cb2565895bc55be72748549e527 Github-Pull: #5879
This commit is contained in:
parent
002c8a2411
commit
c91c660e49
@ -2219,7 +2219,7 @@ bool InvalidateBlock(CValidationState& state, CBlockIndex *pindex) {
|
||||
BlockMap::iterator it = mapBlockIndex.begin();
|
||||
while (it != mapBlockIndex.end()) {
|
||||
if (it->second->IsValid(BLOCK_VALID_TRANSACTIONS) && it->second->nChainTx && setBlockIndexCandidates.value_comp()(chainActive.Tip(), it->second)) {
|
||||
setBlockIndexCandidates.insert(pindex);
|
||||
setBlockIndexCandidates.insert(it->second);
|
||||
}
|
||||
it++;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user