[PATCH] [Support][Windows] Re-enable dialog box disabling on MinGW
Johannes S. Mueller-Roemer
johannes.sebastian.mueller-roemer at igd.fraunhofer.de
Mon Feb 2 00:34:06 PST 2015
D7230 completely removed dialog disabling for MinGW, although MinGW supports it with the proper settings (see D7224).
Todo: _CrtSetReportHook remains ifdef'ed out as for some reason dbghelp.h is not included for MinGW
http://reviews.llvm.org/D7330
Files:
lib/Support/Windows/Signals.inc
Index: lib/Support/Windows/Signals.inc
===================================================================
--- lib/Support/Windows/Signals.inc
+++ lib/Support/Windows/Signals.inc
@@ -275,12 +275,15 @@
// Crash to stack trace handler on abort.
signal(SIGABRT, HandleAbort);
- // The following functions are not reliably accessible on MinGW.
-#ifdef _MSC_VER
+ // The following functions are only available on MinGW if a sufficiently
+ // current MSVCRT is used (the corresponding runtimes must be installed).
+#if defined(_MSC_VER) || __MSVCRT_VERSION__ >= 0x900
// We're already handling writing a "something went wrong" message.
_set_abort_behavior(0, _WRITE_ABORT_MSG);
// Disable Dr. Watson.
_set_abort_behavior(0, _CALL_REPORTFAULT);
+#endif
+#ifdef _MSC_VER
_CrtSetReportHook(AvoidMessageBoxHook);
#endif
EMAIL PREFERENCES
http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D7330.19131.patch
Type: text/x-patch
Size: 839 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150202/6a896cf3/attachment.bin>
More information about the llvm-commits
mailing list