From 1abf2059a7ce22c96b4a97380016d9aaa32bb9f7 Mon Sep 17 00:00:00 2001 From: Augustin Cavalier Date: Thu, 21 Nov 2024 22:36:07 -0500 Subject: [PATCH] BFS: Adjust CachedNode::SetToWritable for consistency with SetTo. Follow-up to an old review comment. --- src/add-ons/kernel/file_systems/bfs/Inode.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/add-ons/kernel/file_systems/bfs/Inode.h b/src/add-ons/kernel/file_systems/bfs/Inode.h index 4ed61961be..077ced4c15 100644 --- a/src/add-ons/kernel/file_systems/bfs/Inode.h +++ b/src/add-ons/kernel/file_systems/bfs/Inode.h @@ -357,6 +357,8 @@ public: status_t SetToWritable(Transaction& transaction, const Inode* inode, bool empty = false) { + Unset(); + fVolume = inode->GetVolume(); return CachedBlock::SetToWritable(transaction, fVolume->VnodeToBlock(inode->ID()), empty); }