From 5e9edb83ade06ce0ffa708ee968faea518535be5 Mon Sep 17 00:00:00 2001 From: Nemoumbra Date: Mon, 10 Aug 2026 23:31:16 +0300 Subject: [PATCH] Fixed passing 'timeout' to 'maxTries' in WebServer --- Core/WebServer.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Core/WebServer.cpp b/Core/WebServer.cpp index 8dd2eec8d8..0f7ad9d36c 100644 --- a/Core/WebServer.cpp +++ b/Core/WebServer.cpp @@ -121,7 +121,7 @@ static bool RegisterServer(int port) { double timeout = success ? 2.0 : 10.0; // We register both IPv4 and IPv6 in case the other client is using a different one. - if (resource4[0] != 0 && http.Connect(timeout)) { + if (resource4[0] != 0 && http.Connect(/*maxTries=*/ 2, timeout)) { if (http.GET(http::RequestParams(resource4), &theVoid, &progress) > 0) success = true; theVoid.Skip(theVoid.size()); @@ -129,7 +129,7 @@ static bool RegisterServer(int port) { } // Currently, we're not using keepalive, so gotta reconnect... - if (http.Connect(timeout)) { + if (http.Connect(/*maxTries=*/ 2, timeout)) { char resource6[1024] = {}; std::string ip = http.GetLocalIpAsString(); snprintf(resource6, sizeof(resource6) - 1, "/match/update?local=%s&port=%d", ip.c_str(), port);