parent
79e79ad1d2
commit
0c1497846e
Notes:
sideshowbarker
2024-07-19 09:02:33 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/0c1497846e7
1 changed files with 2 additions and 0 deletions
|
@ -4511,6 +4511,8 @@ int Process::sys$profiling_enable(pid_t pid)
|
|||
auto* process = Process::from_pid(pid);
|
||||
if (!process)
|
||||
return -ESRCH;
|
||||
if (process->is_dead())
|
||||
return -ESRCH;
|
||||
if (!is_superuser() && process->uid() != m_uid)
|
||||
return -EPERM;
|
||||
Profiling::start(*process);
|
||||
|
|
Loading…
Add table
Reference in a new issue