Doesn't try to get a FS info for non-data partitions anymore.

git-svn-id: file:///srv/svn/repos/haiku/trunk/current@2295 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Ingo Weinhold 2002-12-25 12:08:37 +00:00
parent 6eed52aa01
commit af8f3b2175

View File

@ -83,9 +83,14 @@ partitionInfo->info.device[0] = '\0';
} }
// get the FS info // get the FS info
if (error == B_OK) { if (error == B_OK) {
error = disk_scanner->get_partition_fs_info(deviceFD, partitionInfo); bool hidden = (partitionInfo->flags & B_HIDDEN_PARTITION);
// in case the FS is unknown, we fill in the respective fields if (!hidden) {
if (error == B_ENTRY_NOT_FOUND) { error = disk_scanner->get_partition_fs_info(deviceFD,
partitionInfo);
}
// in case the partition is no data partition or the FS is unknown,
// we fill in the respective fields
if (hidden || error == B_ENTRY_NOT_FOUND) {
error = B_OK; error = B_OK;
partitionInfo->file_system_short_name[0] = '\0'; partitionInfo->file_system_short_name[0] = '\0';
partitionInfo->file_system_long_name[0] = '\0'; partitionInfo->file_system_long_name[0] = '\0';