From 1294f7bbdde787fa39d5789d94401b05128e677e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alex=20R=C3=B8nne=20Petersen?= Date: Sun, 21 Jul 2024 13:25:21 +0200 Subject: [PATCH] std.posix: Don't consider NOSYS a valid error from sigaction(). I know of no "POSIX" system that does not have a sigaction() syscall. Closes #20704. --- lib/std/posix.zig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/std/posix.zig b/lib/std/posix.zig index 98f1ba4a853d..152265aa0de4 100644 --- a/lib/std/posix.zig +++ b/lib/std/posix.zig @@ -5681,7 +5681,7 @@ pub fn sigaltstack(ss: ?*stack_t, old_ss: ?*stack_t) SigaltstackError!void { pub fn sigaction(sig: u6, noalias act: ?*const Sigaction, noalias oact: ?*Sigaction) error{OperationNotSupported}!void { switch (errno(system.sigaction(sig, act, oact))) { .SUCCESS => return, - .INVAL, .NOSYS => return error.OperationNotSupported, + .INVAL => return error.OperationNotSupported, else => unreachable, } }