From a936f41a5d5f7bb97425f82ec64dfae62e840a56 Mon Sep 17 00:00:00 2001 From: Anthony Towns Date: Thu, 25 Feb 2021 00:28:16 +1000 Subject: txorphanage: make m_peer_work_set private --- src/test/fuzz/txorphan.cpp | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'src/test/fuzz/txorphan.cpp') diff --git a/src/test/fuzz/txorphan.cpp b/src/test/fuzz/txorphan.cpp index 730e814e1d..b200f94144 100644 --- a/src/test/fuzz/txorphan.cpp +++ b/src/test/fuzz/txorphan.cpp @@ -89,11 +89,17 @@ FUZZ_TARGET_INIT(txorphan, initialize_orphanage) orphanage.AddChildrenToWorkSet(*tx, peer_id); }, [&] { - bool have_tx = orphanage.HaveTx(GenTxid::Txid(tx->GetHash())) || orphanage.HaveTx(GenTxid::Wtxid(tx->GetHash())); { LOCK(g_cs_orphans); - bool get_tx = orphanage.GetTx(tx->GetHash()).first != nullptr; - Assert(have_tx == get_tx); + NodeId originator; + bool more = true; + CTransactionRef ref = orphanage.GetTxToReconsider(peer_id, originator, more); + if (!ref) { + Assert(!more); + } else { + bool have_tx = orphanage.HaveTx(GenTxid::Txid(ref->GetHash())) || orphanage.HaveTx(GenTxid::Wtxid(ref->GetHash())); + Assert(have_tx); + } } }, [&] { -- cgit v1.2.3