forked from qt-creator/qt-creator
Docker: Fix iterateWithFind()
Amends 22dd26bc76
.
Change-Id: I0be8d8236795a9e93ab93f89df56fd14e378e6e6
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -1522,7 +1522,8 @@ void DockerDevice::iterateWithFind(const FilePath &filePath,
|
|||||||
continue;
|
continue;
|
||||||
const FilePath fp = FilePath::fromString(entry);
|
const FilePath fp = FilePath::fromString(entry);
|
||||||
|
|
||||||
if (!Utils::anyOf(criticalWildcards,
|
if (!criticalWildcards.isEmpty() &&
|
||||||
|
!Utils::anyOf(criticalWildcards,
|
||||||
[name = fp.fileName()](const QString &pattern) {
|
[name = fp.fileName()](const QString &pattern) {
|
||||||
const QRegularExpression regex(QRegularExpression::wildcardToRegularExpression(pattern));
|
const QRegularExpression regex(QRegularExpression::wildcardToRegularExpression(pattern));
|
||||||
if (regex.match(name).hasMatch())
|
if (regex.match(name).hasMatch())
|
||||||
|
Reference in New Issue
Block a user