From: Viktor Szakats Date: Thu, 21 Aug 2025 11:59:46 +0000 (+0200) Subject: curl_setup.h: fix `FMT_SOCKET_T` to be unsigned on Windows X-Git-Tag: rc-8_18_0-2~86 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=86f5bd3c6e67809e4feac4df42e422c54277df05;p=thirdparty%2Fcurl.git curl_setup.h: fix `FMT_SOCKET_T` to be unsigned on Windows To match the Windows socket type. Ref: https://learn.microsoft.com/windows/win32/winsock/socket-data-type-2 Cherry-picked from #18343 Closes #19881 --- diff --git a/lib/curl_setup.h b/lib/curl_setup.h index c4be90b655..829650aee4 100644 --- a/lib/curl_setup.h +++ b/lib/curl_setup.h @@ -519,9 +519,13 @@ #endif #if SIZEOF_CURL_SOCKET_T < 8 +#ifdef _WIN32 +# define FMT_SOCKET_T "u" +#else # define FMT_SOCKET_T "d" -#elif defined(__MINGW32__) -# define FMT_SOCKET_T "zd" +#endif +#elif defined(_WIN32) +# define FMT_SOCKET_T "zu" #else # define FMT_SOCKET_T "qd" #endif