Skip to content

Commit

Permalink
chore: forward log instead of wrap
Browse files Browse the repository at this point in the history
Wrapping log message from wlroots and printing it as a QString adds
extra quotes to raw message. This might be confusing when log message
itself contains double quotes. Just use qPrintable to forward log.
  • Loading branch information
asterwyx authored and zccrs committed Sep 10, 2024
1 parent 0474dbf commit a86ec09
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/util/qwlogging.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,15 @@ class qw_log
{
switch((int)verbosity) {
case WLR_ERROR :
qCCritical(lcQWLog) << QString::vasprintf(fmt, args);
qCCritical(lcQWLog) << qPrintable(QString::vasprintf(fmt, args));
break;

case WLR_INFO :
qCInfo(lcQWLog) << QString::vasprintf(fmt, args);
qCInfo(lcQWLog) << qPrintable(QString::vasprintf(fmt, args));
break;

case WLR_DEBUG :
qCDebug(lcQWLog) << QString::vasprintf(fmt, args);
qCDebug(lcQWLog) << qPrintable(QString::vasprintf(fmt, args));
break;

default:
Expand Down

0 comments on commit a86ec09

Please sign in to comment.