Fix creation of FAT mountpoints.

BUG: 387463
This commit is contained in:
Andrius Štikonas 2017-11-30 23:33:35 +00:00
parent a6ed618ba6
commit d4c72ad075
1 changed files with 13 additions and 2 deletions

View File

@ -60,9 +60,20 @@ EditMountPointDialogWidget::EditMountPointDialogWidget(QWidget* parent, const Pa
}
if (!entryFound) {
QString fsName = partition().fileSystem().name();
if (fsName == FileSystem::nameForType(FileSystem::LinuxSwap))
FileSystem::Type type = partition().fileSystem().type();
QString fsName;
switch (type) {
case FileSystem::LinuxSwap:
fsName = QStringLiteral("swap");
break;
case FileSystem::Fat16:
case FileSystem::Fat32:
fsName = QStringLiteral("vfat");
break;
default:
fsName = partition().fileSystem().name();
}
entry = new FstabEntry(m_deviceNode, QString(), fsName, QString());
m_fstabEntries.append(*entry);
}