Updated soft-fail message

This commit is contained in:
Lexipherous
2024-02-04 18:47:08 +00:00
parent e5f168e2dd
commit 8f4e4cf6b2

View File

@@ -151,7 +151,6 @@ def get_random_port(game_ports):
port = get_port_from_list(available_ports)
if port == 0:
logging.info("Unable to find port. Expanding search to the default ports. (49152-65535)")
checked_ports = []
while len(set(checked_ports)) < (65535-49152)+1:
port = random.randint(49152, 65535)
@@ -159,6 +158,7 @@ def get_random_port(game_ports):
break
else:
checked_ports.append(port)
logging.info(f"Unable to find an available port in custom range. Expanded search to the default ports. Hosting on port {port}.")
return port