mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-05-12 01:46:46 +02:00
Kernel: Do not require 'proc' promise in getsid() and getpgid()
These only require 'stdio' according to: https://man.openbsd.org/pledge.2
This commit is contained in:
committed by
Andreas Kling
parent
74018be739
commit
97d15e9b8f
Notes:
sideshowbarker
2024-07-17 08:37:36 +09:00
Author: https://github.com/trflynn89 Commit: https://github.com/SerenityOS/serenity/commit/97d15e9b8f Pull-request: https://github.com/SerenityOS/serenity/pull/15454
@@ -13,7 +13,7 @@ namespace Kernel {
|
||||
ErrorOr<FlatPtr> Process::sys$getsid(pid_t pid)
|
||||
{
|
||||
VERIFY_PROCESS_BIG_LOCK_ACQUIRED(this);
|
||||
TRY(require_promise(Pledge::proc));
|
||||
TRY(require_promise(Pledge::stdio));
|
||||
if (pid == 0)
|
||||
return sid().value();
|
||||
auto process = Process::from_pid(pid);
|
||||
@@ -49,7 +49,7 @@ ErrorOr<FlatPtr> Process::sys$setsid()
|
||||
ErrorOr<FlatPtr> Process::sys$getpgid(pid_t pid)
|
||||
{
|
||||
VERIFY_PROCESS_BIG_LOCK_ACQUIRED(this);
|
||||
TRY(require_promise(Pledge::proc));
|
||||
TRY(require_promise(Pledge::stdio));
|
||||
if (pid == 0)
|
||||
return pgid().value();
|
||||
auto process = Process::from_pid(pid);
|
||||
|
||||
Reference in New Issue
Block a user