From fa8763135bbc6bdd87f686d22a190771a9de1594 Mon Sep 17 00:00:00 2001 From: Thiago Macieira Date: Sun, 23 Sep 2012 16:14:15 +0200 Subject: [PATCH] Fix compilation: don't call functions you didn't compile These functions are only present on debug builds, on Linux. So don't call them unless this is a debug build, on Linux. Change-Id: I180c4a15fbfec15c585e4a8819a43065dba1e90c Reviewed-by: hjk --- src/app/main.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/app/main.cpp b/src/app/main.cpp index e96692b04fb..fcef58ed991 100644 --- a/src/app/main.cpp +++ b/src/app/main.cpp @@ -229,7 +229,9 @@ int main(int argc, char **argv) const int threadCount = QThreadPool::globalInstance()->maxThreadCount(); QThreadPool::globalInstance()->setMaxThreadCount(qMax(4, 2 * threadCount)); +#if defined(Q_OS_LINUX) && !defined(QT_NO_DEBUG) setupCrashHandler(); // Display a backtrace once a serious signal is delivered. +#endif #ifdef ENABLE_QT_BREAKPAD QtSystemExceptionHandler systemExceptionHandler; @@ -436,6 +438,8 @@ int main(int argc, char **argv) #endif const int r = app.exec(); +#if defined(Q_OS_LINUX) && !defined(QT_NO_DEBUG) cleanupCrashHandler(); +#endif return r; }