Skip to content

Commit 7f20eb1

Browse files
committed
Fix #234: possible injection through .arg() chains
1 parent d7056d1 commit 7f20eb1

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/dbmanager.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2502,9 +2502,8 @@ void DBManager::exportNotes(const QString &baseExportPath, const QString &extens
25022502
counter = 1;
25032503
while (directory.exists(filePath)) {
25042504
filePath = QStringLiteral("%1%2%3 %4%5")
2505-
.arg(notePath, QDir::separator(), safeTitle)
2506-
.arg(counter++)
2507-
.arg(extension);
2505+
.arg(notePath, QDir::separator(), safeTitle,
2506+
QString::number(counter++), extension);
25082507
}
25092508

25102509
// qDebug() << "Exporting note:" << filePath;

0 commit comments

Comments
 (0)