diff --git a/src/modules/luksbootkeyfile/LuksBootKeyFileJob.cpp b/src/modules/luksbootkeyfile/LuksBootKeyFileJob.cpp index ecee92467..e8dfd4724 100644 --- a/src/modules/luksbootkeyfile/LuksBootKeyFileJob.cpp +++ b/src/modules/luksbootkeyfile/LuksBootKeyFileJob.cpp @@ -160,8 +160,8 @@ partitionsFromGlobalStorage() STATICTEST bool hasMountPoint( const QVariantMap& map, const QString& path ) { - const QString mountPoint = map.value( QStringLiteral( "mountPoint" ) ).toString(); - return QDir::cleanPath( mountPoint ) == path; + const auto v = map.value( QStringLiteral( "mountPoint" ) ); + return v.isValid() && QDir::cleanPath( v.toString() ) == path; } STATICTEST bool