aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJon Atack <jon@atack.com>2023-08-11 16:12:42 -0600
committerJon Atack <jon@atack.com>2024-05-10 22:29:51 -0600
commit684da9707040ce25d95b2954eda50b811136d92c (patch)
tree33bce0b61a9dd16a7545555086c46099af1023be /src
parent2cedb42a928fbf3a1e0e8715e918497cbe64af0d (diff)
downloadbitcoin-684da9707040ce25d95b2954eda50b811136d92c.tar.xz
p2p, bugfix: detect addnode cjdns peers in GetAddedNodeInfo()
Addnode (manual) peers connected to us via the cjdns network are currently not detected by CConnman::GetAddedNodeInfo(), i.e. fConnected is always false. This causes the following issues: - RPC `getaddednodeinfo` incorrectly shows them as not connected - CConnman::ThreadOpenAddedConnections() continually retries to connect them
Diffstat (limited to 'src')
-rw-r--r--src/net.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/net.cpp b/src/net.cpp
index ad1e464667..7a64d3ce04 100644
--- a/src/net.cpp
+++ b/src/net.cpp
@@ -2832,7 +2832,7 @@ std::vector<AddedNodeInfo> CConnman::GetAddedNodeInfo(bool include_connected) co
}
for (const auto& addr : lAddresses) {
- CService service(LookupNumeric(addr.m_added_node, GetDefaultPort(addr.m_added_node)));
+ CService service{MaybeFlipIPv6toCJDNS(LookupNumeric(addr.m_added_node, GetDefaultPort(addr.m_added_node)))};
AddedNodeInfo addedNode{addr, CService(), false, false};
if (service.IsValid()) {
// strAddNode is an IP:port