From 70ebf4dd965abb6fef1c8faf8cff75330a0b342f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Philip=20M=C3=BCller?= Date: Fri, 2 Nov 2018 23:42:27 +0100 Subject: [PATCH] [partition] mount only read-only --- src/modules/partition/core/PartUtils.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/modules/partition/core/PartUtils.cpp b/src/modules/partition/core/PartUtils.cpp index d7c543bd2..3fbdab6bd 100644 --- a/src/modules/partition/core/PartUtils.cpp +++ b/src/modules/partition/core/PartUtils.cpp @@ -164,9 +164,8 @@ lookForFstabEntries( const QString& partitionPath ) { FstabEntryList fstabEntries; QTemporaryDir mountsDir; - mountsDir.setAutoRemove( false ); - int exit = QProcess::execute( "mount", { partitionPath, mountsDir.path() } ); + int exit = QProcess::execute( "mount", "-o", "ro,noload", { partitionPath, mountsDir.path() } ); if ( !exit ) // if all is well { QFile fstabFile( mountsDir.path() + "/etc/fstab" );