summaryrefslogtreecommitdiffstats
path: root/tools/qmlplugindump/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tools/qmlplugindump/main.cpp')
-rw-r--r--tools/qmlplugindump/main.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/tools/qmlplugindump/main.cpp b/tools/qmlplugindump/main.cpp
index 2b2bb85a..88d8fcea 100644
--- a/tools/qmlplugindump/main.cpp
+++ b/tools/qmlplugindump/main.cpp
@@ -68,6 +68,10 @@
#ifdef Q_OS_UNIX
#include <signal.h>
#endif
+#ifdef Q_OS_WIN
+#include <crtdbg.h>
+#include <qt_windows.h>
+#endif
QString pluginImportPath;
bool verbose = false;
@@ -533,6 +537,13 @@ void printUsage(const QString &appName)
int main(int argc, char *argv[])
{
+#ifdef Q_OS_WIN
+ // we do not want windows popping up if the module loaded triggers an assert
+ SetErrorMode(SEM_NOGPFAULTERRORBOX);
+ _CrtSetReportMode(_CRT_ASSERT, _CRTDBG_MODE_DEBUG);
+ _CrtSetReportMode(_CRT_WARN, _CRTDBG_MODE_DEBUG);
+ _CrtSetReportMode(_CRT_ERROR, _CRTDBG_MODE_DEBUG);
+#endif
#ifdef Q_OS_UNIX
// qmldump may crash, but we don't want any crash handlers to pop up
// therefore we intercept the segfault and just exit() ourselves