From 5fa4055452861ca1700008e1761815e88b29fae7 Mon Sep 17 00:00:00 2001 From: brunoerg Date: Sat, 10 Jun 2023 08:05:10 -0300 Subject: [PATCH] net: do not `break` when `addr` is not from a distinct network group When the address is from a network group we already caught, do a `continue` and try to find another address until conditions are met or we reach the limit (`nTries`). --- src/net.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/net.cpp b/src/net.cpp index 282c8fb7414..46b67386abf 100644 --- a/src/net.cpp +++ b/src/net.cpp @@ -1853,7 +1853,7 @@ void CConnman::ThreadOpenConnections(const std::vector connect) // Require outbound IPv4/IPv6 connections, other than feelers, to be to distinct network groups if (!fFeeler && outbound_ipv46_peer_netgroups.count(m_netgroupman.GetGroup(addr))) { - break; + continue; } // if we selected an invalid or local address, restart