Refactor check for EFI system.

The TODO stands, to delegate this to KPMCore.
This commit is contained in:
Adriaan de Groot 2017-08-28 05:36:21 -04:00
parent 106f18e074
commit 7e66499f36
10 changed files with 31 additions and 21 deletions

View file

@ -151,7 +151,7 @@ canBeResized( PartitionCoreModule* core, const QString& partitionPath )
}
FstabEntryList
static FstabEntryList
lookForFstabEntries( const QString& partitionPath )
{
FstabEntryList fstabEntries;
@ -195,7 +195,7 @@ lookForFstabEntries( const QString& partitionPath )
}
QString
static QString
findPartitionPathForMountPoint( const FstabEntryList& fstab,
const QString& mountPoint )
{
@ -328,4 +328,10 @@ runOsprober( PartitionCoreModule* core )
return osproberEntries;
}
bool
isEfiSystem()
{
return QDir( "/sys/firmware/efi/efivars" ).exists();
}
} // nmamespace PartUtils