Commit 1bac9319 authored by Alexander Lohnau's avatar Alexander Lohnau 💬

Skip . and .. dirs when listing entries

parent 9965606f
......@@ -487,13 +487,10 @@ void countFiles(const QString &path, unsigned long &totalFiles, bool &stop)
return;
}
for (const QString& name : dir.entryList()) {
for (const QString& name : dir.entryList(QDir::NoDotAndDotDot)) {
if (stop)
return;
if (name == QStringLiteral(".") || name == QStringLiteral(".."))
continue;
countFiles(dir.absoluteFilePath(name), totalFiles, stop);
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment