From de3c56ee1e67998b69c509fa5238b2e5440b806f Mon Sep 17 00:00:00 2001 From: codereader Date: Sat, 4 Mar 2017 13:26:51 +0100 Subject: [PATCH] Remove __stdcall from DLL exported code to fix the 32 Bit builds __stdcall applies name mangling even if extern C is specified. Since we don't use a .def file anymore in Win32 this problem appeared in the 2.2.1 release. --- include/imodule.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/include/imodule.h b/include/imodule.h index dbbf6daa3c..ff9c0579f8 100644 --- a/include/imodule.h +++ b/include/imodule.h @@ -328,9 +328,10 @@ namespace module { #if defined(WIN32) #if defined(_MSC_VER) // In VC++ we use this to export symbols instead of using .def files - #define DARKRADIANT_DLLEXPORT __declspec(dllexport) __stdcall + // Note: don't use __stdcall since this is adding stack bytes to the function name + #define DARKRADIANT_DLLEXPORT __declspec(dllexport) #else - #define DARKRADIANT_DLLEXPORT __stdcall + #define DARKRADIANT_DLLEXPORT #endif #else #define DARKRADIANT_DLLEXPORT