mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-01-19 23:03:45 +01:00
Pass mempool pointer to UnloadBlockIndex
This commit is contained in:
@@ -4587,13 +4587,13 @@ void CChainState::UnloadBlockIndex() {
|
||||
// May NOT be used after any connections are up as much
|
||||
// of the peer-processing logic assumes a consistent
|
||||
// block index state
|
||||
void UnloadBlockIndex()
|
||||
void UnloadBlockIndex(CTxMemPool* mempool)
|
||||
{
|
||||
LOCK(cs_main);
|
||||
g_chainman.Unload();
|
||||
pindexBestInvalid = nullptr;
|
||||
pindexBestHeader = nullptr;
|
||||
mempool.clear();
|
||||
if (mempool) mempool->clear();
|
||||
vinfoBlockFile.clear();
|
||||
nLastBlockFile = 0;
|
||||
setDirtyBlockIndex.clear();
|
||||
|
||||
Reference in New Issue
Block a user