wallet: avoid rescans if under the snapshot

Refuse to load a wallet if it requires a rescan lower than the height of
an unvalidated snapshot we're running -- in more general terms, if we
don't have data for the blocks.
This commit is contained in:
James O'Beirne
2019-03-29 17:10:11 -04:00
committed by James O'Beirne
parent d0bf9bb6a5
commit 817326a828
3 changed files with 22 additions and 3 deletions

View File

@@ -723,6 +723,11 @@ public:
notifications.transactionAddedToMempool(entry.GetSharedTx(), 0 /* mempool_sequence */);
}
}
bool hasAssumedValidChain() override
{
return Assert(m_node.chainman)->IsSnapshotActive();
}
NodeContext& m_node;
};
} // namespace