GetLocalAddrForPeer

Returns a local address that we should advertise to this peer.

Synopsis

Declared in <net.h>

std::optional<CService>
GetLocalAddrForPeer(CNode& node);

Return Value

the address to advertise, or std::nullopt if none is suitable.

Parameters

NameDescription
nodethe peer we would advertise the address to.