mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 04:17:35 +00:00
FileSystem: Remove now-unused Inode::parent() and Inode::reverse_lookup().
These were only used to implement the old path resolution algorithm.
This commit is contained in:
parent
02e21de20a
commit
2e14e5891c
7 changed files with 0 additions and 94 deletions
|
@ -739,11 +739,6 @@ RetainPtr<Inode> ProcFS::create_directory(InodeIdentifier, const String&, mode_t
|
|||
return nullptr;
|
||||
}
|
||||
|
||||
RetainPtr<Inode> ProcFSInode::parent() const
|
||||
{
|
||||
return fs().get_inode(to_parent_id(identifier()));
|
||||
}
|
||||
|
||||
InodeIdentifier ProcFS::root_inode() const
|
||||
{
|
||||
return { fsid(), FI_Root };
|
||||
|
@ -1042,26 +1037,6 @@ InodeIdentifier ProcFSInode::lookup(const String& name)
|
|||
return { };
|
||||
}
|
||||
|
||||
String ProcFSInode::reverse_lookup(InodeIdentifier child_id)
|
||||
{
|
||||
ASSERT(is_directory());
|
||||
auto proc_file_type = to_proc_file_type(identifier());
|
||||
if (proc_file_type == FI_Root) {
|
||||
for (auto& entry : fs().m_entries) {
|
||||
if (child_id == to_identifier(fsid(), PDI_Root, 0, (ProcFileType)entry.proc_file_type)) {
|
||||
return entry.name;
|
||||
}
|
||||
}
|
||||
auto child_proc_file_type = to_proc_file_type(child_id);
|
||||
if (child_proc_file_type == FI_PID)
|
||||
return String::format("%u", to_pid(child_id));
|
||||
return { };
|
||||
}
|
||||
// FIXME: Implement
|
||||
ASSERT_NOT_REACHED();
|
||||
return { };
|
||||
}
|
||||
|
||||
void ProcFSInode::flush_metadata()
|
||||
{
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue