mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-27 11:48:32 +00:00
ProcFS: Take the "all inodes" lock when generating /proc/inodes
Otherwise the kernel asserts.
This commit is contained in:
@@ -914,6 +914,7 @@ static Optional<KBuffer> procfs$inodes(InodeIdentifier)
|
||||
{
|
||||
KBufferBuilder builder;
|
||||
InterruptDisabler disabler;
|
||||
ScopedSpinLock all_inodes_lock(Inode::all_inodes_lock());
|
||||
for (auto& inode : Inode::all_with_lock()) {
|
||||
builder.appendf("Inode{K%x} %02u:%08u (%u)\n", &inode, inode.fsid(), inode.index(), inode.ref_count());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user