MEONMedical / Log4Qt

Log4Qt - Logging for the Qt cross-platform application framework
Apache License 2.0
589 stars 235 forks source link

dailyfileappender.cpp,need add #include <QStringBuilder> #40

Closed libaineu2004 closed 4 years ago

libaineu2004 commented 4 years ago

dailyfileappender.cpp,need add #include < QStringBuilder >

QString DailyFileAppender::appendDateToFilename() const { QFileInfo fi(mOriginalFilename); return fi.absolutePath() % QStringLiteral("/") % fi.baseName() % mLastDate.toString(mDatePattern) % QStringLiteral(".") % fi.completeSuffix(); }

Because "%" is an overloaded operator, if the source file does not include this header file #include < QStringBuilder >, it will conflict with "%" overloaded operators of other third-party libraries.

andibacher commented 4 years ago

Fixed in the master and next version.