node/coinstats: Pass in BlockManager to GetUTXOStats

This commit is contained in:
Carl Dong
2020-09-01 16:15:57 -04:00
parent 2c3ba00693
commit 106bcd4f39
5 changed files with 14 additions and 12 deletions

View File

@@ -264,7 +264,7 @@ FUZZ_TARGET_INIT(coins_view, initialize_coins_view)
CCoinsStats stats;
bool expected_code_path = false;
try {
(void)GetUTXOStats(&coins_view_cache, stats, CoinStatsHashType::HASH_SERIALIZED);
(void)GetUTXOStats(&coins_view_cache, WITH_LOCK(::cs_main, return std::ref(g_chainman.m_blockman)), stats, CoinStatsHashType::HASH_SERIALIZED);
} catch (const std::logic_error&) {
expected_code_path = true;
}