Fix log file Dir

This commit is contained in:
Simon De Backer
2020-08-15 21:40:07 +02:00
parent dff825810c
commit 5832e365e9

View File

@@ -109,8 +109,8 @@ void myMessageOutput(QtMsgType type,
txt+= context.function ? context.function : "";
txt+=")\n";
}
QFile outFile(QDir::homePath()
+"/.qet/"
QFile outFile(QETApp::configDir()
+"/"
+QDate::currentDate().toString("yyyyMMdd")
+".log");
if(outFile.open(QIODevice::WriteOnly | QIODevice::Append))
@@ -129,7 +129,7 @@ void myMessageOutput(QtMsgType type,
void delete_old_log_files(int days)
{
const QDate today = QDate::currentDate();
const QString path = QDir::homePath() + "/.qet/";
const QString path = QETApp::configDir() + "/";
QString filter("%1%1%1%1%1%1%1%1.log"); // pattern
filter = filter.arg("[0123456789]"); // valid characters