diff --git a/src/test/fuzz/p2p_headers_presync.cpp b/src/test/fuzz/p2p_headers_presync.cpp index 3a7146df8fe..b31b74ee4fe 100644 --- a/src/test/fuzz/p2p_headers_presync.cpp +++ b/src/test/fuzz/p2p_headers_presync.cpp @@ -32,6 +32,12 @@ public: PeerManager::Options peerman_opts; node::ApplyArgsManOptions(*m_node.args, peerman_opts); peerman_opts.max_headers_result = FUZZ_MAX_HEADERS_RESULTS; + // The peerman's rng is a global that is re-used, so it will be re-used + // and may cause non-determinism between runs. This may even influence + // the global RNG, because seeding may be done from the gloabl one. For + // now, avoid it influencing the global RNG, and initialize it with a + // constant instead. + peerman_opts.deterministic_rng = true; // No txs are relayed. Disable irrelevant and possibly // non-deterministic code paths. peerman_opts.ignore_incoming_txs = true;