mirror of
https://github.com/RGBCube/serenity
synced 2025-05-23 19:15:07 +00:00
Add parent PIDs to /proc/summary
This commit is contained in:
parent
16f318408d
commit
86a547dcac
2 changed files with 5 additions and 2 deletions
|
@ -24,13 +24,14 @@ bool ProcFileSystem::initialize()
|
|||
auto stringImpl = StringImpl::createUninitialized(tasks.size() * 256, buffer);
|
||||
memset(buffer, 0, stringImpl->length());
|
||||
char* ptr = buffer;
|
||||
ptr += ksprintf(ptr, "PID OWNER STATE NSCHED FDS NAME\n");
|
||||
ptr += ksprintf(ptr, "PID OWNER STATE PPID NSCHED FDS NAME\n");
|
||||
for (auto* task : tasks) {
|
||||
ptr += ksprintf(ptr, "%w %w:%w %b %w %w %s\n",
|
||||
ptr += ksprintf(ptr, "%w %w:%w %b %w %w %w %s\n",
|
||||
task->pid(),
|
||||
task->uid(),
|
||||
task->gid(),
|
||||
task->state(),
|
||||
task->parentPID(),
|
||||
task->timesScheduled(),
|
||||
task->fileHandleCount(),
|
||||
task->name().characters());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue