File 0263-esock-Silence-compiler-warning-on-Windows.patch of Package erlang
From 21b5837a4c26f874da8415da6a8ce09ecdd83886 Mon Sep 17 00:00:00 2001
From: Micael Karlberg <bmk@erlang.org>
Date: Mon, 20 May 2024 19:35:43 +0200
Subject: [PATCH] [esock] Silence compiler warning on Windows
Add two pragma-statements (disable + default)
to silence a compiler warning.
---
erts/emulator/nifs/win32/win_socket_asyncio.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/erts/emulator/nifs/win32/win_socket_asyncio.c b/erts/emulator/nifs/win32/win_socket_asyncio.c
index 7516c0b0c8..504e74543d 100644
--- a/erts/emulator/nifs/win32/win_socket_asyncio.c
+++ b/erts/emulator/nifs/win32/win_socket_asyncio.c
@@ -3845,7 +3845,9 @@ void encode_cmsgs(ErlNifEnv* env,
/* nifs\win32\win_socket_asyncio.c(3167):
* warning C4116: unnamed type definition in parentheses
*/
+#pragma warning(disable:4116)
currentP = ESOCK_CMSG_NXTHDR(msgP, currentP)) {
+#pragma warning(default:4116)
SSDBG( descP,
("WIN-ESAIO", "encode_cmsgs {%d} -> process cmsg header when"
--
2.35.3