diff options
author | Carl Dong <contact@carldong.me> | 2020-08-25 15:23:57 -0400 |
---|---|---|
committer | Carl Dong <contact@carldong.me> | 2020-09-15 14:11:34 -0400 |
commit | 74f73c783d46b012f375d819e2cd09c792820cd5 (patch) | |
tree | 9c351abe4519267e6c57ce65b195b819e2ca3e2e /src/qt | |
parent | 4668ded6d6ea4299d998abbb57543f37519812e2 (diff) |
validation: Pass in chainman to UnloadBlockIndex
Diffstat (limited to 'src/qt')
-rw-r--r-- | src/qt/test/apptests.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/qt/test/apptests.cpp b/src/qt/test/apptests.cpp index 0b5c341548..8dffd2f59f 100644 --- a/src/qt/test/apptests.cpp +++ b/src/qt/test/apptests.cpp @@ -84,8 +84,11 @@ void AppTests::appTests() // Reset global state to avoid interfering with later tests. LogInstance().DisconnectTestLogger(); AbortShutdown(); - UnloadBlockIndex(/* mempool */ nullptr); - WITH_LOCK(::cs_main, g_chainman.Reset()); + { + LOCK(cs_main); + UnloadBlockIndex(/* mempool */ nullptr, g_chainman); + g_chainman.Reset(); + } } //! Entry point for BitcoinGUI tests. |