mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-02-18 13:44:50 +00:00
Kernel/Ext2: Check and set file system state
This is supposed to detect whether a file system was unmounted cleanly or not.
This commit is contained in:
committed by
Jelle Raaijmakers
parent
8fb126bec6
commit
251b17085b
@@ -30,6 +30,7 @@ FileSystem::~FileSystem()
|
||||
ErrorOr<void> FileSystem::prepare_to_unmount(Inode& mount_guest_inode)
|
||||
{
|
||||
return m_attach_count.with([&](auto& attach_count) -> ErrorOr<void> {
|
||||
dbgln_if(VFS_DEBUG, "VFS: File system {} (id {}) is attached {} time(s)", class_name(), m_fsid.value(), attach_count);
|
||||
if (attach_count == 1)
|
||||
return prepare_to_clear_last_mount(mount_guest_inode);
|
||||
return {};
|
||||
|
||||
Reference in New Issue
Block a user