Fixed a bug that would rescan the boot partition in mount_file_systems() in
case it couldn't be used for booting (lack of a kernel or whatever). git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7243 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
** Copyright 2003, Axel Dörfler, [email protected]. All rights reserved.
|
** Copyright 2003-2004, Axel Dörfler, [email protected]. All rights reserved.
|
||||||
** Distributed under the terms of the OpenBeOS License.
|
** Distributed under the terms of the OpenBeOS License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@@ -317,11 +317,15 @@ get_boot_file_system(stage2_args *args)
|
|||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
Directory *fileSystem;
|
Directory *fileSystem;
|
||||||
if (partition->Mount(&fileSystem) < B_OK) {
|
status_t status = partition->Mount(&fileSystem);
|
||||||
|
|
||||||
|
gPartitions.Remove(partition);
|
||||||
// let's remove that partition, so that it is not scanned again
|
// let's remove that partition, so that it is not scanned again
|
||||||
// in mount_file_systems()
|
// in mount_file_systems()
|
||||||
|
|
||||||
gPartitions.Remove(partition);
|
if (status < B_OK) {
|
||||||
|
// this partition doesn't contain any known file system; we
|
||||||
|
// don't need it anymore
|
||||||
delete partition;
|
delete partition;
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user