Make the partition ID check more flexible, if partitions just pop up out of
nowhere, we still want to be able to automount them, even though the notification is not for a device. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30720 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -200,9 +200,15 @@ AutoMounter::_MountVolumes(mount_mode normal, mount_mode removable,
|
||||
{
|
||||
if (fOnlyOnDeviceID >= 0) {
|
||||
// only mount partitions on the given device id
|
||||
// or if the partition ID is already matched
|
||||
BPartition* device = partition;
|
||||
while (device->Parent() != NULL)
|
||||
while (device->Parent() != NULL) {
|
||||
if (device->ID() == fOnlyOnDeviceID) {
|
||||
// we are happy
|
||||
break;
|
||||
}
|
||||
device = device->Parent();
|
||||
}
|
||||
if (device->ID() != fOnlyOnDeviceID)
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user