Skip to content

Commit

Permalink
Fixes for LP Bug #1797746 / noquote for QT5
Browse files Browse the repository at this point in the history
Fix for https://bugs.launchpad.net/mixxx/+bug/1797746

Without this patch, debugging messages in mixxx.log are
quoted since QT > 5.4, which breaks output of engine.log()
escape characters.

This patch adds .noquote() to QDebug if QT_VERSION >= 5.4
  • Loading branch information
banad60 committed Oct 22, 2018
1 parent da4d160 commit 25588ae
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/controllers/controllerdebug.h
Expand Up @@ -30,10 +30,17 @@ class ControllerDebug {
// We prefix every log message with Logging::kControllerDebugPrefix so that we
// can bypass the --logLevel commandline argument when --controllerDebug is
// specified.
//
// In order of Bug #1797746, since transition to qt5 it is needed unquote the
// output for mixxx.log with .noquote(), because in qt5 QDebug() is quoted by default.
#define controllerDebug(stream) \
{ \
if (ControllerDebug::enabled()) { \
#if QT_VERSION > 0x050399
QDebug(QtDebugMsg).noquote() << ControllerDebug::kLogMessagePrefix << stream; \
#else
QDebug(QtDebugMsg) << ControllerDebug::kLogMessagePrefix << stream; \
#endif
} \
} \

Expand Down

0 comments on commit 25588ae

Please sign in to comment.