From: "cron2 (Code Review)" Date: Mon, 8 Dec 2025 14:41:50 +0000 In-Reply-To: References: Reply-To: gert@...1296..., arne-openvpn@...1227..., openvpn-devel@lists.sourceforge.net, frank@...2641... Message-ID: <28878e5485a49b770387d74c9eba3518e175ac2e-HTML@...2715...> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Disposition: inline Content-Type: multipart/alternative; boundary="B1T//4gwKOU="; charset=UTF-8 Subject: [Openvpn-devel] [XS] Change in openvpn[master]: CMake: For VS build, switch from /W2 to /W3 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: flichtenheld Cc: plaisthos , openvpn-devel --B1T//4gwKOU= Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable cron2 has submitted this change. ( http://gerrit.openvpn.net/c/openvpn/+/14= 17?usp=3Demail ) Change subject: CMake: For VS build, switch from /W2 to /W3 ...................................................................... CMake: For VS build, switch from /W2 to /W3 But exclude the added checks that currently have failures so that we can keep /WX enabled. Basically this excludes -Wconversion and -Wsign-compare, as expected from our GCC/Clang flags. Github: #382 Change-Id: Iffc114939cb37129057e9c4864fae9e09c3c7fe4 Signed-off-by: Frank Lichtenheld Acked-by: Gert Doering Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1417 Message-Id: <20251208113636.9650-1-gert@...1296...> URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg34= 876.html Signed-off-by: Gert Doering --- M CMakeLists.txt 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index b3142e4..906fa04 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -85,9 +85,12 @@ if (USE_WERROR) add_compile_options(/WX) endif () + # C4018: signed/unsigned mismatch + # C4244: conversion from 'type1' to 'type2', possible loss of data + # C4267: conversion from 'size_t' to 'type', possible loss of data add_compile_options( /MP - /W2 + /W3 /wd4018 /wd4267 /wd4244 /sdl /Qspectre /guard:cf -- To view, visit http://gerrit.openvpn.net/c/openvpn/+/1417?usp=3Demail To unsubscribe, or for help writing mail filters, visit http://gerrit.openv= pn.net/settings?usp=3Demail Gerrit-MessageType: merged Gerrit-Project: openvpn Gerrit-Branch: master Gerrit-Change-Id: Iffc114939cb37129057e9c4864fae9e09c3c7fe4 Gerrit-Change-Number: 1417 Gerrit-PatchSet: 4 Gerrit-Owner: flichtenheld Gerrit-Reviewer: cron2 Gerrit-Reviewer: plaisthos Gerrit-CC: openvpn-devel --B1T//4gwKOU= Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable

cron2 sub= mitted this change.

View Change

CMake: For VS build, switch from /W2 to /W3
<= br>But exclude the added checks that currently have failures
so that we = can keep /WX enabled.
Basically this excludes -Wconversion and -Wsign-co= mpare,
as expected from our GCC/Clang flags.

Github: #382
Chan= ge-Id: Iffc114939cb37129057e9c4864fae9e09c3c7fe4
Signed-off-by: Frank Li= chtenheld <frank@...2641...>
Acked-by: Gert Doering <gert@...1711...= 96...>
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1417
Mes= sage-Id: <20251208113636.9650-1-gert@...1296...>
URL: https://www.= mail-archive.com/openvpn-devel@lists.sourceforge.net/msg34876.html
Signe= d-off-by: Gert Doering <gert@...1296...>
---
M CMakeLists.txt1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index b3142= e4..906fa04 100644
--- a/CMakeLists.txt
+++= b/CMakeLists.txt
@@ -85,9 +85,12 @@
i= f (USE_WERROR)
add_compile_options(/WX)
= endif ()
+= # C4018: signed/unsigned mismatch
+ # C4244: conversion from 'type1' to 'type= 2', possible loss of data
+ # C4267: conversion from 'size_t' to 'type', = possible loss of data
add_compile_options(
<= span> /MP
- = /W2
+ /W3 = /wd4018 /wd4267 /wd4244
/sdl
= /Qspectre
/guard:cf

To view, visit change 1417. To unsubscribe, or for help writing mail = filters, visit s= ettings.

=
Gerrit-MessageType: merged
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Iffc114939cb37129057e9c4864f= ae9e09c3c7fe4
Gerrit-Change-Number: 1417
Gerrit-PatchSet: 4
Gerrit-Owner: flichtenheld <frank@...2723...= .>
Gerrit-Reviewer: cron2 <gert@...1296...>=
Gerrit-Reviewer: plaisthos <arne-openvpn@...1186...= .1227...>
Gerrit-CC: openvpn-devel <openvpn-devel@...1484...= ts.sourceforge.net>
= --B1T//4gwKOU=--