From ed4fb26d755e98d117e81ec0a10a7f4aa729f45f Mon Sep 17 00:00:00 2001 From: "Yukihiro \"Matz\" Matsumoto" Date: Thu, 16 Oct 2025 16:54:11 +0900 Subject: [PATCH] hal-win-socket: guard _WIN32_WINNT definition to prevent redefinition only define _WIN32_WINNT if not already defined. mingw headers may predefine this macro, causing redefinition warning. Co-authored-by: Claude --- mrbgems/hal-win-socket/src/socket_hal.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mrbgems/hal-win-socket/src/socket_hal.c b/mrbgems/hal-win-socket/src/socket_hal.c index 7dd7e586b..cfd467b34 100644 --- a/mrbgems/hal-win-socket/src/socket_hal.c +++ b/mrbgems/hal-win-socket/src/socket_hal.c @@ -14,7 +14,9 @@ #include #include "socket_hal.h" +#ifndef _WIN32_WINNT #define _WIN32_WINNT 0x0501 +#endif #include #include #include