Skip to content

Commit c2d751a

Browse files
committed
net: take CJDNS into account in CNetAddr::GetReachabilityFrom()
This way `GetLocal()` will pick our CJDNS address for a CJDNS peer.
1 parent 9b43b3b commit c2d751a

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/netaddress.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -892,6 +892,11 @@ int CNetAddr::GetReachabilityFrom(const CNetAddr *paddrPartner) const
892892
case NET_I2P: return REACH_PRIVATE;
893893
default: return REACH_DEFAULT;
894894
}
895+
case NET_CJDNS:
896+
switch (ourNet) {
897+
case NET_CJDNS: return REACH_PRIVATE;
898+
default: return REACH_DEFAULT;
899+
}
895900
case NET_TEREDO:
896901
switch(ourNet) {
897902
default: return REACH_DEFAULT;

0 commit comments

Comments
 (0)