mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-11 22:50:59 +01:00
Merge #21162: Net Processing: Move RelayTransaction() into PeerManager
680eb56d82[net processing] Don't pass CConnman to RelayTransactions (John Newbery)a38a4e8f03[net processing] Move RelayTransaction into PeerManager (John Newbery) Pull request description: This is the first part of #21160. It moves the RelayTransaction() function to be a member function of the PeerManager class. This is required in order to move the transaction inventory data into the Peer object, since Peer objects are only accessible from within PeerManager. ACKs for top commit: ajtowns: ACK680eb56d82Tree-SHA512: 8c93491a4392b6369bb7f090de326a63cd62a088de59026e202f226f64ded50a0cf1a95ed703328860f02a9d2f64d3a87ca1bca9a6075b978bd111d384766235
This commit is contained in:
@@ -47,6 +47,10 @@ public:
|
||||
/** Whether this node ignores txs received over p2p. */
|
||||
virtual bool IgnoresIncomingTxs() = 0;
|
||||
|
||||
/** Relay transaction to all peers. */
|
||||
virtual void RelayTransaction(const uint256& txid, const uint256& wtxid)
|
||||
EXCLUSIVE_LOCKS_REQUIRED(cs_main) = 0;
|
||||
|
||||
/** Send ping message to all peers */
|
||||
virtual void SendPings() = 0;
|
||||
|
||||
@@ -71,7 +75,4 @@ public:
|
||||
const std::chrono::microseconds time_received, const std::atomic<bool>& interruptMsgProc) = 0;
|
||||
};
|
||||
|
||||
/** Relay transaction to every node */
|
||||
void RelayTransaction(const uint256& txid, const uint256& wtxid, const CConnman& connman) EXCLUSIVE_LOCKS_REQUIRED(cs_main);
|
||||
|
||||
#endif // BITCOIN_NET_PROCESSING_H
|
||||
|
||||
Reference in New Issue
Block a user