summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRagnar Thomsen <[email protected]>2015-05-31 13:24:33 +0200
committerRagnar Thomsen <[email protected]>2015-05-31 13:24:33 +0200
commit0b315d81d31fa78fd219acfb2680209c2e114f57 (patch)
treef0c8b9c493cb290aa7261bf1ac07d59a38ffb688
parentf36cc4de55b54d971e60c3bcd2ede668e94426c7 (diff)
Adddialog: Make QString s in foreach loop a const ref
Since QString s is not being modified in the foreach loop, make it a const reference to avoid creating new QString objects.
-rw-r--r--kerfuffle/adddialog.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/kerfuffle/adddialog.cpp b/kerfuffle/adddialog.cpp
index c0e8c05..45aed46 100644
--- a/kerfuffle/adddialog.cpp
+++ b/kerfuffle/adddialog.cpp
@@ -128,7 +128,7 @@ void AddDialog::loadConfiguration()
// with empty comments are discarded.
QMimeDatabase db;
QMap<QString,QMimeType> mimeMap;
- foreach (QString s, writeMimeTypes) {
+ foreach (const QString &s, writeMimeTypes) {
QMimeType mime(db.mimeTypeForName(s));
if (!mime.comment().isEmpty()) {
mimeMap[mime.comment()] = mime;