MCPcopy Create free account
hub / github.com/bitcoin/bitcoin / IsAddrCompatible

Function IsAddrCompatible

src/net_processing.cpp:1128–1131  ·  view source on GitHub ↗

* Whether the peer supports the address. For example, a peer that does not * implement BIP155 cannot receive Tor v3 addresses because it requires * ADDRv2 (BIP155) encoding. */

Source from the content-addressed store, hash-verified

1126 * ADDRv2 (BIP155) encoding.
1127 */
1128static bool IsAddrCompatible(const Peer& peer, const CAddress& addr)
1129{
1130 return peer.m_wants_addrv2 || addr.IsAddrV1Compatible();
1131}
1132
1133void PeerManagerImpl::AddAddressKnown(Peer& peer, const CAddress& addr)
1134{

Callers 3

PushAddressMethod · 0.85
RelayAddressMethod · 0.85
MaybeSendAddrMethod · 0.85

Calls 1

IsAddrV1CompatibleMethod · 0.80

Tested by

no test coverage detected