Add (not really necessary) locking of the sMountMutex in case of KDEBUG to keep the assert in find_mount() happy.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26484 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
eb0dca1d33
commit
541959e00a
@ -6500,7 +6500,11 @@ fs_unmount(char *path, dev_t mountID, uint32 flags, bool kernel)
|
|||||||
|
|
||||||
RecursiveLocker mountOpLocker(sMountOpLock);
|
RecursiveLocker mountOpLocker(sMountOpLock);
|
||||||
|
|
||||||
|
// this lock is not strictly necessary, but here in case of KDEBUG
|
||||||
|
// to keep the ASSERT in find_mount() working.
|
||||||
|
KDEBUG_ONLY(mutex_lock(&sMountMutex));
|
||||||
mount = find_mount(path != NULL ? vnode->device : mountID);
|
mount = find_mount(path != NULL ? vnode->device : mountID);
|
||||||
|
KDEBUG_ONLY(mutex_unlock(&sMountMutex));
|
||||||
if (mount == NULL) {
|
if (mount == NULL) {
|
||||||
panic("fs_unmount: find_mount() failed on root vnode @%p of mount\n",
|
panic("fs_unmount: find_mount() failed on root vnode @%p of mount\n",
|
||||||
vnode);
|
vnode);
|
||||||
|
Loading…
Reference in New Issue
Block a user