aboutsummaryrefslogtreecommitdiff
path: root/src/validation.cpp
diff options
context:
space:
mode:
authorJon Atack <jon@atack.com>2022-02-09 14:01:32 +0100
committerJon Atack <jon@atack.com>2022-02-09 15:38:36 +0100
commitdaad0093e3d1466789d0ce687902636c80cd74a1 (patch)
treec173134e31c193e4ca81538f564a00a0ff8254e1 /src/validation.cpp
parent6ac637f97f0ccdf0c6ab8565f68d37aeffe62090 (diff)
validation: replace lock with annotation in UnloadBlockIndex()
Diffstat (limited to 'src/validation.cpp')
-rw-r--r--src/validation.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/validation.cpp b/src/validation.cpp
index e20e2fe523..438e375988 100644
--- a/src/validation.cpp
+++ b/src/validation.cpp
@@ -4028,7 +4028,7 @@ void CChainState::UnloadBlockIndex() {
// block index state
void UnloadBlockIndex(CTxMemPool* mempool, ChainstateManager& chainman)
{
- LOCK(cs_main);
+ AssertLockHeld(::cs_main);
chainman.Unload();
pindexBestHeader = nullptr;
if (mempool) mempool->clear();