mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 16:07:46 +00:00
Kernel: Move process parent PID into protected data :^)
This commit is contained in:
parent
d677a73b0e
commit
3d27269f13
4 changed files with 6 additions and 6 deletions
|
@ -36,7 +36,7 @@ KResultOr<int> Process::sys$disown(ProcessID pid)
|
|||
return ESRCH;
|
||||
if (process->ppid() != this->pid())
|
||||
return ECHILD;
|
||||
process->m_ppid = 0;
|
||||
MutableProtectedData(*this)->ppid = 0;
|
||||
process->disowned_by_waiter(*this);
|
||||
return 0;
|
||||
}
|
||||
|
|
|
@ -38,7 +38,7 @@ KResultOr<pid_t> Process::sys$getpid()
|
|||
KResultOr<pid_t> Process::sys$getppid()
|
||||
{
|
||||
REQUIRE_PROMISE(stdio);
|
||||
return m_ppid.value();
|
||||
return protected_data().ppid.value();
|
||||
}
|
||||
|
||||
KResultOr<int> Process::sys$get_process_name(Userspace<char*> buffer, size_t buffer_size)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue