Now marks a partition unmounted on unmount - that allows a volume to be remounted as often as you like.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14036 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -5154,8 +5154,11 @@ fs_unmount(char *path, uint32 flags, bool kernel)
|
|||||||
// release the file system
|
// release the file system
|
||||||
put_file_system(mount->fs);
|
put_file_system(mount->fs);
|
||||||
|
|
||||||
// dereference the partition
|
// dereference the partition and mark it unmounted
|
||||||
if (partition) {
|
if (partition) {
|
||||||
|
partition->SetVolumeID(-1);
|
||||||
|
partition->SetMountCookie(NULL);
|
||||||
|
|
||||||
if (mount->owns_file_device)
|
if (mount->owns_file_device)
|
||||||
KDiskDeviceManager::Default()->DeleteFileDevice(partition->ID());
|
KDiskDeviceManager::Default()->DeleteFileDevice(partition->ID());
|
||||||
partition->Unregister();
|
partition->Unregister();
|
||||||
|
|||||||
Reference in New Issue
Block a user