mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-05 08:06:09 +00:00
Kernel/FileSystem: Simplify the ProcFS inode code
This is done by merging all scattered pieces of derived classes from the ProcFSInode class into that one class, so we don't use inheritance but rather simplistic checks to determine the proper code for each ProcFS inode with its specific characteristics.
This commit is contained in:
committed by
Jelle Raaijmakers
parent
e9dcc49f9c
commit
722ae35329
@@ -6,8 +6,8 @@
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
||||
#include <Kernel/FileSystem/ProcFS/DirectoryInode.h>
|
||||
#include <Kernel/FileSystem/ProcFS/FileSystem.h>
|
||||
#include <Kernel/FileSystem/ProcFS/Inode.h>
|
||||
#include <Kernel/ProcessExposed.h>
|
||||
|
||||
namespace Kernel {
|
||||
@@ -22,7 +22,7 @@ ProcFS::~ProcFS() = default;
|
||||
|
||||
ErrorOr<void> ProcFS::initialize()
|
||||
{
|
||||
m_root_inode = static_ptr_cast<ProcFSDirectoryInode>(TRY(ProcFSComponentRegistry::the().root_directory().to_inode(*this)));
|
||||
m_root_inode = TRY(ProcFSComponentRegistry::the().root_directory().to_inode(*this));
|
||||
return {};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user