mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-03-27 16:05:39 +01:00
Merge bitcoin/bitcoin#25514: net processing: Move CNode::nServices and CNode::nLocalServices to Peer
8d8eeb422e[net processing] Remove CNode::nLocalServices (John Newbery)5961f8eea1[net] Return CService from GetLocalAddrForPeer and GetLocalAddress (dergoegge)d9079fe18d[net processing] Remove CNode::nServices (John Newbery)7d1c036934[net processing] Replace fHaveWitness with CanServeWitnesses() (John Newbery)f65e83d51b[net processing] Remove fClient and m_limited_node (John Newbery)fc5eb528f7[tests] Connect peer in outbound_slow_chain_eviction by sending p2p messages (John Newbery)1f52c47d5c[net processing] Add m_our_services and m_their_services to Peer (John Newbery) Pull request description: Another step in #19398. Which services we offer to a peer and which services they offer to us is application layer data and should not be stored on `CNode`. This is also a prerequisite for adding `PeerManager` unit tests (See #25515). ACKs for top commit: MarcoFalke: ACK8d8eeb422e🔑 jnewbery: utACK8d8eeb422emzumsande: Code Review ACK8d8eeb422eTree-SHA512: e772eb2a0a85db346dd7b453a41011a12756fc7cbfda6a9ef6daa9633b9a47b9770ab3dc02377690f9d02127301c3905ff22905977f758bf90b17a9a35b37523
This commit is contained in:
@@ -195,8 +195,9 @@ static RPCHelpMan getpeerinfo()
|
||||
if (stats.m_mapped_as != 0) {
|
||||
obj.pushKV("mapped_as", uint64_t(stats.m_mapped_as));
|
||||
}
|
||||
obj.pushKV("services", strprintf("%016x", stats.nServices));
|
||||
obj.pushKV("servicesnames", GetServicesNames(stats.nServices));
|
||||
ServiceFlags services{fStateStats ? statestats.their_services : ServiceFlags::NODE_NONE};
|
||||
obj.pushKV("services", strprintf("%016x", services));
|
||||
obj.pushKV("servicesnames", GetServicesNames(services));
|
||||
obj.pushKV("lastsend", count_seconds(stats.m_last_send));
|
||||
obj.pushKV("lastrecv", count_seconds(stats.m_last_recv));
|
||||
obj.pushKV("last_transaction", count_seconds(stats.m_last_tx_time));
|
||||
|
||||
Reference in New Issue
Block a user