mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-09-30 00:31:14 +00:00
Kernel: Reject sigaction() with SA_SIGINFO
We can't handle this, so let sigaction() fail instead of PANIC()'ing later when we try to dispatch a signal with SA_SIGINFO set.
This commit is contained in:
parent
cf63447044
commit
848eaf2220
Notes:
sideshowbarker
2024-07-17 17:57:25 +09:00
Author: https://github.com/alimpfard Commit: https://github.com/SerenityOS/serenity/commit/848eaf2220 Pull-request: https://github.com/SerenityOS/serenity/pull/12762
|
@ -68,6 +68,8 @@ ErrorOr<FlatPtr> Process::sys$sigaction(int signum, Userspace<const sigaction*>
|
|||
}
|
||||
if (user_act) {
|
||||
auto act = TRY(copy_typed_from_user(user_act));
|
||||
if (act.sa_flags & SA_SIGINFO)
|
||||
return ENOTSUP;
|
||||
action.mask = act.sa_mask;
|
||||
action.flags = act.sa_flags;
|
||||
action.handler_or_sigaction = VirtualAddress { reinterpret_cast<void*>(act.sa_sigaction) };
|
||||
|
|
Loading…
Reference in a new issue