From 388a34cdf145367730dc14f4e9246caf52c269f6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Henrik=20Rydg=C3=A5rd?= Date: Sun, 17 Sep 2023 22:40:08 +0200 Subject: [PATCH] HTTPClient: On Windows, we have to permit connect to "fail" with an errno of 0. Wacky. --- Common/Net/HTTPClient.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Common/Net/HTTPClient.cpp b/Common/Net/HTTPClient.cpp index c5c72d1a22..b68ad6bfe9 100644 --- a/Common/Net/HTTPClient.cpp +++ b/Common/Net/HTTPClient.cpp @@ -131,7 +131,7 @@ bool Connection::Connect(int maxTries, double timeout, bool *cancelConnect) { // Start trying to connect (async with timeout.) errno = 0; if (connect(sock, possible->ai_addr, (int)possible->ai_addrlen) < 0) { - if (errno != EINPROGRESS) { + if (errno != 0 && errno != EINPROGRESS) { char addrStr[128]; FormatAddr(addrStr, sizeof(addrStr), possible); if (errno != ENETUNREACH) {