Make sure all pattern args get cleared when parsing a new pattern
The user can call qSetMessagePattern after program start, so we need to be sure that the parsed argument data is properly cleared. Task-number: QTBUG-57144 Change-Id: I1978c6b95bd84639a8c4fffd1487429b04725522 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
This commit is contained in:
parent
50aeedd86c
commit
20526cb014
@ -1039,6 +1039,10 @@ void QMessagePattern::setPattern(const QString &pattern)
|
||||
delete [] literals;
|
||||
}
|
||||
delete [] tokens;
|
||||
timeArgs.clear();
|
||||
#ifdef QLOGGING_HAVE_BACKTRACE
|
||||
backtraceArgs.clear();
|
||||
#endif
|
||||
|
||||
// scanner
|
||||
QList<QString> lexemes;
|
||||
|
Loading…
Reference in New Issue
Block a user