MCPcopy Create free account
hub / github.com/ElementsProject/elements / FUZZ_TARGET_INIT

Function FUZZ_TARGET_INIT

src/test/fuzz/load_external_block_file.cpp:26–36  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

24}
25
26FUZZ_TARGET_INIT(load_external_block_file, initialize_load_external_block_file)
27{
28 FuzzedDataProvider fuzzed_data_provider{buffer.data(), buffer.size()};
29 FuzzedFileProvider fuzzed_file_provider = ConsumeFile(fuzzed_data_provider);
30 FILE* fuzzed_block_file = fuzzed_file_provider.open();
31 if (fuzzed_block_file == nullptr) {
32 return;
33 }
34 FlatFilePos flat_file_pos;
35 g_setup->m_node.chainman->ActiveChainstate().LoadExternalBlockFile(fuzzed_block_file, fuzzed_data_provider.ConsumeBool() ? &flat_file_pos : nullptr);
36}

Callers

nothing calls this directly

Calls 6

ConsumeFileFunction · 0.85
LoadExternalBlockFileMethod · 0.80
ConsumeBoolMethod · 0.80
dataMethod · 0.45
sizeMethod · 0.45
openMethod · 0.45

Tested by

no test coverage detected