From e6679f9d0da980ecb1c893af3a54844e752636cf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Axel=20D=C3=B6rfler?= Date: Thu, 7 Aug 2008 17:37:07 +0000 Subject: [PATCH] * Since we're using ASSERT macros, still lock/unlock the nodes when initializing the file system. * This fixes bug #2580. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26865 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/add-ons/kernel/file_systems/bfs/Journal.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/add-ons/kernel/file_systems/bfs/Journal.cpp b/src/add-ons/kernel/file_systems/bfs/Journal.cpp index 831c30331d..9b6f9c5a50 100644 --- a/src/add-ons/kernel/file_systems/bfs/Journal.cpp +++ b/src/add-ons/kernel/file_systems/bfs/Journal.cpp @@ -1072,8 +1072,6 @@ Transaction::Start(Volume* volume, off_t refBlock) void Transaction::AddInode(Inode* inode) { - if (GetVolume()->IsInitializing()) - return; if (fJournal == NULL) panic("Transaction is not running!"); @@ -1085,7 +1083,8 @@ Transaction::AddInode(Inode* inode) } } - acquire_vnode(GetVolume()->FSVolume(), inode->ID()); + if (!GetVolume()->IsInitializing()) + acquire_vnode(GetVolume()->FSVolume(), inode->ID()); rw_lock_write_lock(&inode->fLock); fLockedInodes.Add(inode); } @@ -1096,7 +1095,8 @@ Transaction::_UnlockInodes() { while (Inode* inode = fLockedInodes.RemoveHead()) { rw_lock_write_unlock(&inode->fLock); - put_vnode(GetVolume()->FSVolume(), inode->ID()); + if (!GetVolume()->IsInitializing()) + put_vnode(GetVolume()->FSVolume(), inode->ID()); } }