mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2026-04-28 14:50:24 +00:00
Add CoreInode::reverse_lookup().
Getting the absolute path of an ext2fs inode now uses the lookup cache which makes it a lot faster.
This commit is contained in:
parent
5f434bc00b
commit
eced5f11e3
Notes:
sideshowbarker
2024-07-19 16:10:30 +09:00
Author: https://github.com/awesomekling
Commit: eced5f11e3
7 changed files with 61 additions and 74 deletions
|
|
@ -37,20 +37,6 @@ FileSystem* FileSystem::fromID(dword id)
|
|||
return nullptr;
|
||||
}
|
||||
|
||||
String FileSystem::name_of_child_in_directory(InodeIdentifier parent, InodeIdentifier child) const
|
||||
{
|
||||
String name;
|
||||
bool success = enumerateDirectoryInode(parent, [&] (auto& entry) {
|
||||
if (entry.inode == child) {
|
||||
name = entry.name;
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
});
|
||||
ASSERT(success);
|
||||
return name;
|
||||
}
|
||||
|
||||
ByteBuffer CoreInode::read_entire(FileDescriptor* descriptor)
|
||||
{
|
||||
return fs().readEntireInode(identifier(), descriptor);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue