diff --git a/src/common/logging/text_formatter.cpp b/src/common/logging/text_formatter.cpp index 8583916a8e..2bfb6ce4b9 100644 --- a/src/common/logging/text_formatter.cpp +++ b/src/common/logging/text_formatter.cpp @@ -31,7 +31,7 @@ std::string FormatLogMessage(const Entry& entry) { } void PrintMessage(const Entry& entry) { - auto str = FormatLogMessage(entry) + '\n'; + const auto str = FormatLogMessage(entry).append(1, '\n'); fputs(str.c_str(), stderr); }