mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-11 06:28:31 +01:00
fuzz: Initialize a full TestingSetup where appropriate
A full TestingSetup is required for both coins_view and load_external_block_file as they interact with the active chainstate.
This commit is contained in:
@@ -36,9 +36,7 @@ bool operator==(const Coin& a, const Coin& b)
|
|||||||
|
|
||||||
void initialize_coins_view()
|
void initialize_coins_view()
|
||||||
{
|
{
|
||||||
static const ECCVerifyHandle ecc_verify_handle;
|
static const auto testing_setup = MakeFuzzingContext<const TestingSetup>();
|
||||||
ECC_Start();
|
|
||||||
SelectParams(CBaseChainParams::REGTEST);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
FUZZ_TARGET_INIT(coins_view, initialize_coins_view)
|
FUZZ_TARGET_INIT(coins_view, initialize_coins_view)
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
|
|
||||||
void initialize_load_external_block_file()
|
void initialize_load_external_block_file()
|
||||||
{
|
{
|
||||||
static const auto testing_setup = MakeFuzzingContext<>();
|
static const auto testing_setup = MakeFuzzingContext<const TestingSetup>();
|
||||||
}
|
}
|
||||||
|
|
||||||
FUZZ_TARGET_INIT(load_external_block_file, initialize_load_external_block_file)
|
FUZZ_TARGET_INIT(load_external_block_file, initialize_load_external_block_file)
|
||||||
|
|||||||
Reference in New Issue
Block a user