diff options
Diffstat (limited to 'src/rpc/net.cpp')
-rw-r--r-- | src/rpc/net.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/rpc/net.cpp b/src/rpc/net.cpp index e221b3462d..d701a180ab 100644 --- a/src/rpc/net.cpp +++ b/src/rpc/net.cpp @@ -947,7 +947,8 @@ static RPCHelpMan addpeeraddress() bool success{false}; if (LookupHost(addr_string, net_addr, false)) { - CAddress address{{net_addr, port}, ServiceFlags{NODE_NETWORK | NODE_WITNESS}}; + CService service{net_addr, port}; + CAddress address{MaybeFlipIPv6toCJDNS(service), ServiceFlags{NODE_NETWORK | NODE_WITNESS}}; address.nTime = Now<NodeSeconds>(); // The source address is set equal to the address. This is equivalent to the peer // announcing itself. |