aboutsummaryrefslogtreecommitdiff
path: root/src/node
diff options
context:
space:
mode:
authorMarcoFalke <falke.marco@gmail.com>2022-01-05 16:23:55 +0100
committerMarcoFalke <falke.marco@gmail.com>2022-01-05 16:15:04 +0100
commitfab262174b96854d2df5bee7da578990c9e9cb1e (patch)
tree475886d4eeed03785c333733a6b625365d15e095 /src/node
parentfa467f3913918701c765f9bc754203b4591b894f (diff)
Move blockstorage-related unload to BlockManager::Unload
This is a refactor and safe to do because: * UnloadBlockIndex calls ChainstateManager::Unload, which calls BlockManager::Unload * Only unit tests call Unload directly
Diffstat (limited to 'src/node')
-rw-r--r--src/node/blockstorage.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/node/blockstorage.cpp b/src/node/blockstorage.cpp
index 3cc53e27e2..a040f2e7b4 100644
--- a/src/node/blockstorage.cpp
+++ b/src/node/blockstorage.cpp
@@ -348,6 +348,11 @@ void BlockManager::Unload()
}
m_block_index.clear();
+
+ vinfoBlockFile.clear();
+ nLastBlockFile = 0;
+ setDirtyBlockIndex.clear();
+ setDirtyFileInfo.clear();
}
bool BlockManager::WriteBlockIndexDB()