Remove Chainstate::LoadMempool

The 3-line function is only called once outside of tests, so it is
clearer to inline it.
This commit is contained in:
MarcoFalke
2023-08-07 10:59:50 +02:00
parent b7138252ac
commit 6888886cec
4 changed files with 8 additions and 13 deletions

View File

@@ -20,6 +20,7 @@
#include <vector>
using kernel::DumpMempool;
using kernel::LoadMempool;
using node::MempoolPath;
@@ -47,6 +48,7 @@ FUZZ_TARGET(validation_load_mempool, .init = initialize_validation_load_mempool)
auto fuzzed_fopen = [&](const fs::path&, const char*) {
return fuzzed_file_provider.open();
};
(void)chainstate.LoadMempool(MempoolPath(g_setup->m_args), fuzzed_fopen);
(void)LoadMempool(pool, MempoolPath(g_setup->m_args), chainstate, fuzzed_fopen);
pool.SetLoadTried(true);
(void)DumpMempool(pool, MempoolPath(g_setup->m_args), fuzzed_fopen, true);
}