mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-22 09:19:03 +00:00
Kernel: Avoid ninja-import of global variable
This would have caused an issue later when we enable -Wmissing-declarations, as the compiler didn't see that Kernel::all_inodes() was being used elsewhere, too. Also, this means that if the type changes later, there's not going to be weird run-time issues, but rather a nice type error during compile time.
This commit is contained in:
committed by
Andreas Kling
parent
ef9a3b8e46
commit
5e48eda218
@@ -900,10 +900,9 @@ static Optional<KBuffer> procfs$all(InodeIdentifier)
|
||||
|
||||
static Optional<KBuffer> procfs$inodes(InodeIdentifier)
|
||||
{
|
||||
extern InlineLinkedList<Inode>& all_inodes();
|
||||
KBufferBuilder builder;
|
||||
InterruptDisabler disabler;
|
||||
for (auto& inode : all_inodes()) {
|
||||
for (auto& inode : Inode::all_with_lock()) {
|
||||
builder.appendf("Inode{K%x} %02u:%08u (%u)\n", &inode, inode.fsid(), inode.index(), inode.ref_count());
|
||||
}
|
||||
return builder.build();
|
||||
|
||||
Reference in New Issue
Block a user