1713@@ -1714,6 +1714,9 @@ CBlockIndex* CWallet::ScanForWalletTransactions(CBlockIndex* pindexStart, CBlock
1714
1715 CBlockIndex* pindex = pindexStart;
1716 CBlockIndex* ret = nullptr;
1717+
1718+ if (pindex) LogPrintf("Rescan started from block %d...\n", pindex->nHeight);
If !pindex, doesn’t that mean Rescan started from block 0...
?
No, if !pindex
the loop below won’t run.
Nit, could use pindexStart
instead so it’s more obvious?
Nah it’s fine, I was just confused then, it looked a bit strange to conditionally log this message.
Indeed. I just want to prevent a nullptr access in case of stupid future changes (not possible now).
Nit: I’d be down for an early return based on pIndexStart
being null, given in that case all else is irrelevant.
@empact Right that seems like a clear solution, though we can do that later, this has enough utACKs I’m going to merge now.