From 09ce3c9ce47231b730ee7bcacb78951b47c1277c Mon Sep 17 00:00:00 2001 From: Cameron Gutman Date: Wed, 2 Nov 2022 19:19:00 -0500 Subject: [PATCH] Use CRLF line endings for the log file on Windows --- app/main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/main.cpp b/app/main.cpp index 40d2b8fb..44f27e62 100644 --- a/app/main.cpp +++ b/app/main.cpp @@ -305,7 +305,7 @@ int main(int argc, char *argv[]) #ifdef LOG_TO_FILE QDir tempDir(Path::getLogDir()); s_LoggerFile = new QFile(tempDir.filePath(QString("Moonlight-%1.log").arg(QDateTime::currentSecsSinceEpoch()))); - if (s_LoggerFile->open(QIODevice::WriteOnly)) { + if (s_LoggerFile->open(QIODevice::WriteOnly | QIODevice::Text)) { QTextStream(stderr) << "Redirecting log output to " << s_LoggerFile->fileName() << Qt::endl; s_LoggerStream.setDevice(s_LoggerFile); }