mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-01-21 07:39:08 +01:00
Merge bitcoin/bitcoin#21719: refactor: Add and use EnsureConnman in rpc code
fafb68add5refactor: Add and use EnsureConnman in rpc code (MarcoFalke)faabeb854arefactor: Mark member functions const (MarcoFalke) Pull request description: This removes the 10 occurrences of `throw JSONRPCError(RPC_CLIENT_P2P_DISABLED, "Error: Peer-to-peer functionality missing or disabled");` and replaces them with `EnsureConnman`. ACKs for top commit: jarolrod: re-ACKfafb68add5theStack: ACKfafb68add5ryanofsky: Code review ACKfafb68add5Tree-SHA512: 84c63cfe31e548645d906f7191a3526c7bea99ed0d54c2a75c2041452a44fe149ede343d8e1943b0e7770816c828bb047dfec8bc541a1f2b89920a126ee54d68
This commit is contained in:
@@ -246,7 +246,7 @@ public:
|
||||
|
||||
/** Implement PeerManager */
|
||||
void CheckForStaleTipAndEvictPeers() override;
|
||||
bool GetNodeStateStats(NodeId nodeid, CNodeStateStats& stats) override;
|
||||
bool GetNodeStateStats(NodeId nodeid, CNodeStateStats& stats) const override;
|
||||
bool IgnoresIncomingTxs() override { return m_ignore_incoming_txs; }
|
||||
void SendPings() override;
|
||||
void RelayTransaction(const uint256& txid, const uint256& wtxid) override;
|
||||
@@ -1103,7 +1103,7 @@ PeerRef PeerManagerImpl::RemovePeer(NodeId id)
|
||||
return ret;
|
||||
}
|
||||
|
||||
bool PeerManagerImpl::GetNodeStateStats(NodeId nodeid, CNodeStateStats &stats)
|
||||
bool PeerManagerImpl::GetNodeStateStats(NodeId nodeid, CNodeStateStats& stats) const
|
||||
{
|
||||
{
|
||||
LOCK(cs_main);
|
||||
|
||||
Reference in New Issue
Block a user