RtlSetProcessIsCritical, RtlSetThreadIsCritical and RtlRestoreContext use
cdecl calling convention. This information is taken from:
https://www.geoffchappell.com/studies/windows/win32/ntdll/api/rtl/peb/setprocessiscritical.htm
https://gitlab.winehq.org/wine/wine/-/blob/wine-10.15/dlls/ntdll/ntdll.spec
https://processhacker.sourceforge.io/doc/ntrtl_8h.html

So remove stdcall symbol mangling from the lib32/ntdll.def file for them.
---
 mingw-w64-crt/lib32/ntdll.def | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/mingw-w64-crt/lib32/ntdll.def b/mingw-w64-crt/lib32/ntdll.def
index 93b8e801ab1b..2685cca04225 100644
--- a/mingw-w64-crt/lib32/ntdll.def
+++ b/mingw-w64-crt/lib32/ntdll.def
@@ -1462,7 +1462,7 @@ RtlResetMemoryZone@4
 RtlResetNtUserPfn@0
 RtlResetRtlTranslations@4
 RtlRestoreBootStatusDefaults@4
-RtlRestoreContext@8
+RtlRestoreContext
 RtlRestoreLastWin32Error@4
 RtlRestoreSystemBootStatusDefaults@0
 RtlRestoreThreadPreferredUILanguages@4
@@ -1507,7 +1507,7 @@ RtlSetMemoryStreamSize@12
 RtlSetOwnerSecurityDescriptor@12
 RtlSetPortableOperatingSystem@4
 RtlSetProcessDebugInformation@12
-RtlSetProcessIsCritical@0
+RtlSetProcessIsCritical
 RtlSetProcessPlaceholderCompatibilityMode@4
 RtlSetProcessPreferredUILanguages@12
 RtlSetProtectedPolicy@12
@@ -1520,7 +1520,7 @@ RtlSetSecurityObjectEx@24
 RtlSetSystemBootStatus@16
 RtlSetSystemBootStatusEx@12
 RtlSetThreadErrorMode@8
-RtlSetThreadIsCritical@0
+RtlSetThreadIsCritical
 RtlSetThreadPlaceholderCompatibilityMode@4
 RtlSetThreadPoolStartFunc@8
 RtlSetThreadPreferredUILanguages2@16
-- 
2.20.1



_______________________________________________
Mingw-w64-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to