[0.4.11][NTDLL_APITEST] Mute 1 MSVC2010SP1 x86 dbg warning C4717 CORE-18104
authorJoachim Henze <Joachim.Henze@reactos.org>
Mon, 28 Mar 2022 12:12:30 +0000 (14:12 +0200)
committerJoachim Henze <Joachim.Henze@reactos.org>
Mon, 28 Mar 2022 12:12:30 +0000 (14:12 +0200)
can be observed with MSVC 2010SP1 (16.0.40219.1) x86 target in dbg configuation:
c:\047rls\reactos\modules\rostests\apitests\ntdll\stackoverflow.c(57) : warning C4717: 'infinite_recursive' : recursive on all control paths, function will cause runtime stack overflow

Muting is okay here, because stack overflow is specifically what is aimed to be tested here.

Fix is a partial pick of 0.4.14-dev-847-g 42d2d5ec9c76588624412f95114d26f36373959f

No warnings left in module NTDLL_APITEST and no C4717 left in releases/0.4.7.

modules/rostests/apitests/ntdll/StackOverflow.c

index 794e2fe..175142d 100644 (file)
@@ -7,6 +7,10 @@
 
 #include "precomp.h"
 
+#ifdef _MSC_VER
+#pragma warning(disable : 4717) // disable warning about recursive function
+#endif
+
 static int iteration = 0;
 static PVOID StackAllocationBase;
 static PVOID LastStackAllocation;