* The Tracker now makes use of the new B_DISK_SYSTEM_SUPPORTS_WRITING flag,
and will only show the "mount me read-only?" dialog when the file system actually supports writing in the first place. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28067 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -46,6 +46,7 @@ All rights reserved.
|
||||
# include <DiskDevice.h>
|
||||
# include <DiskDeviceList.h>
|
||||
# include <DiskDeviceTypes.h>
|
||||
# include <DiskSystem.h>
|
||||
# include <fs_volume.h>
|
||||
#endif
|
||||
|
||||
@@ -199,6 +200,11 @@ AutoMounter::_SuggestMountFlags(const BPartition* partition,
|
||||
isBFS = true;
|
||||
}
|
||||
|
||||
BDiskSystem diskSystem;
|
||||
status_t status = partition->GetDiskSystem(&diskSystem);
|
||||
if (status == B_OK && !diskSystem.SupportsWriting())
|
||||
askReadOnly = false;
|
||||
|
||||
if (partition->IsReadOnly())
|
||||
askReadOnly = false;
|
||||
|
||||
@@ -529,7 +535,7 @@ AutoMounter::GetSettings(BMessage *message)
|
||||
if (fs_stat_dev(volume.Device(), &info) == 0
|
||||
&& info.flags & (B_FS_IS_REMOVABLE | B_FS_IS_PERSISTENT)) {
|
||||
message->AddString(info.device_name, info.volume_name);
|
||||
|
||||
|
||||
BString mountFlagsKey(info.device_name);
|
||||
mountFlagsKey << kMountFlagsKeyExtension;
|
||||
uint32 mountFlags = 0;
|
||||
|
||||
Reference in New Issue
Block a user