From: Jacek Caban jacek@codeweavers.com
--- dlls/winecrt0/exception.c | 6 ++++++ include/excpt.h | 8 ++++++-- 2 files changed, 12 insertions(+), 2 deletions(-)
diff --git a/dlls/winecrt0/exception.c b/dlls/winecrt0/exception.c index 58cf91172ac..ab4224cf4c2 100644 --- a/dlls/winecrt0/exception.c +++ b/dlls/winecrt0/exception.c @@ -18,6 +18,12 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */
+#include "excpt.h" +#undef USE_COMPILER_EXCEPTIONS +#undef GetExceptionInformation +#undef GetExceptionCode +#undef AbnormalTermination + #include <stdarg.h> #include "winternl.h" #include "wine/exception.h" diff --git a/include/excpt.h b/include/excpt.h index 3369f3b1547..17c7409c636 100644 --- a/include/excpt.h +++ b/include/excpt.h @@ -38,7 +38,11 @@ typedef enum _EXCEPTION_DISPOSITION #define EXCEPTION_CONTINUE_EXECUTION -1
-#if defined(_MSC_VER) && defined(USE_COMPILER_EXCEPTIONS) +#if !defined(USE_COMPILER_EXCEPTIONS) && defined(_MSC_VER) && !defined(__i386__) && !defined(__arm__) && (!defined(__clang_major__) || __clang_major__ >= 19) +#define USE_COMPILER_EXCEPTIONS +#endif + +#ifdef USE_COMPILER_EXCEPTIONS #define GetExceptionCode _exception_code #define GetExceptionInformation (struct _EXCEPTION_POINTERS *)_exception_info #define AbnormalTermination _abnormal_termination @@ -46,6 +50,6 @@ typedef enum _EXCEPTION_DISPOSITION unsigned long __cdecl _exception_code(void); void * __cdecl _exception_info(void); int __cdecl _abnormal_termination(void); -#endif /* defined(_MSC_VER) && defined(USE_COMPILER_EXCEPTIONS) */ +#endif /* USE_COMPILER_EXCEPTIONS */
#endif /* __WINE_EXCPT_H */