From 49b3d3a92a7250e80c56ff8c351cf1670e32c1a2 Mon Sep 17 00:00:00 2001 From: marcofleon Date: Thu, 31 Jul 2025 12:18:51 +0100 Subject: [PATCH] Clean up `FindTxForGetData` Adds back a comment that was unintentionally deleted in the GenTxid refactor. --- src/net_processing.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/net_processing.cpp b/src/net_processing.cpp index 61439f71883..28e6cc7bb88 100644 --- a/src/net_processing.cpp +++ b/src/net_processing.cpp @@ -2393,12 +2393,12 @@ void PeerManagerImpl::ProcessGetBlockData(CNode& pfrom, Peer& peer, const CInv& CTransactionRef PeerManagerImpl::FindTxForGetData(const Peer::TxRelay& tx_relay, const GenTxid& gtxid) { + // If a tx was in the mempool prior to the last INV for this peer, permit the request. auto txinfo{std::visit( [&](const auto& id) EXCLUSIVE_LOCKS_REQUIRED(NetEventsInterface::g_msgproc_mutex) { return m_mempool.info_for_relay(id, tx_relay.m_last_inv_sequence); }, gtxid)}; - if (txinfo.tx) { return std::move(txinfo.tx); }