diff options
author | Ulf Hermann <ulf.hermann@qt.io> | 2019-01-25 17:10:14 +0100 |
---|---|---|
committer | Ulf Hermann <ulf.hermann@qt.io> | 2019-04-24 07:33:25 +0000 |
commit | c642f44448752972f89a121b125873f187e088b3 (patch) | |
tree | 24c8f667d3bd1ca3b1b0ca21cb1cf3a26970c4d9 /src/qml/debugger/qqmldebug.cpp | |
parent | c018df5b4075ae962966d4df7653d476dab02840 (diff) |
Tooling: Use fprintf rather than qDebug() for debug warning
This warning is generated from a statically called ctor. At that point
the system facilities to run QMessageLogger may not be in place, yet. In
addition, we actually don't want the message to go through the regular
QMessageLogger redirection and possibly filtering. The message should
always be shown.
Fixes: QTBUG-73217
Change-Id: Ief192dae8c38d5d94996ee9285e54b5cbd714f4b
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
(cherry-picked from commit 15525d2a309a6028d548797bc777e38905f36c46)
Diffstat (limited to 'src/qml/debugger/qqmldebug.cpp')
-rw-r--r-- | src/qml/debugger/qqmldebug.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/qml/debugger/qqmldebug.cpp b/src/qml/debugger/qqmldebug.cpp index 6246fb4207..6532576e03 100644 --- a/src/qml/debugger/qqmldebug.cpp +++ b/src/qml/debugger/qqmldebug.cpp @@ -44,16 +44,16 @@ #include <private/qqmlengine_p.h> #include <private/qv4compileddata_p.h> +#include <cstdio> + QT_REQUIRE_CONFIG(qml_debug); QT_BEGIN_NAMESPACE QQmlDebuggingEnabler::QQmlDebuggingEnabler(bool printWarning) { - if (!QQmlEnginePrivate::qml_debugging_enabled - && printWarning) { - qDebug("QML debugging is enabled. Only use this in a safe environment."); - } + if (!QQmlEnginePrivate::qml_debugging_enabled && printWarning) + fprintf(stderr, "QML debugging is enabled. Only use this in a safe environment.\n"); QQmlEnginePrivate::qml_debugging_enabled = true; } |