summaryrefslogtreecommitdiffstats
path: root/src/corelib/global
diff options
context:
space:
mode:
authorMilian Wolff <milian.wolff@kdab.com>2019-03-26 15:23:48 +0100
committerMilian Wolff <milian.wolff@kdab.com>2019-04-05 11:57:46 +0000
commit5f62202e6c89269da3e9faaea4c88d0f19416cc1 (patch)
tree47c510d6defdd9b0ec8ab5aa1b3e23f4d851dac5 /src/corelib/global
parent6ce2a87c23bbaacece7d32df276f64a0058e447d (diff)
Add tracepoint to qt_message_print
This allows us to deduce a lot about what a Qt application is doing, since the debug output usually contains a lot of information. Change-Id: I28a18afd151a1640a44ba8c7c9cd87d5d66c99b0 Reviewed-by: Christoph Sterz <christoph.sterz@kdab.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/corelib/global')
-rw-r--r--src/corelib/global/qlogging.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/corelib/global/qlogging.cpp b/src/corelib/global/qlogging.cpp
index 168934c202..30232170fb 100644
--- a/src/corelib/global/qlogging.cpp
+++ b/src/corelib/global/qlogging.cpp
@@ -57,6 +57,7 @@
#include "private/qloggingregistry_p.h"
#include "private/qcoreapplication_p.h"
#include "private/qsimd_p.h"
+#include <qtcore_tracepoints_p.h>
#endif
#ifdef Q_OS_WIN
#include <qt_windows.h>
@@ -1811,6 +1812,8 @@ static void ungrabMessageHandler() { }
static void qt_message_print(QtMsgType msgType, const QMessageLogContext &context, const QString &message)
{
#ifndef QT_BOOTSTRAPPED
+ Q_TRACE(qt_message_print, msgType, context.category, context.function, context.file, context.line, message);
+
// qDebug, qWarning, ... macros do not check whether category is enabled
if (isDefaultCategory(context.category)) {
if (QLoggingCategory *defaultCategory = QLoggingCategory::defaultCategory()) {