std.os.linux: remove app_mask

This commit is contained in:
Misaki Kasumi
2024-12-28 11:19:02 +08:00
committed by Alex Rønne Petersen
parent d72f3d353f
commit cc65eaf0a9
2 changed files with 0 additions and 8 deletions

View File

@@ -5113,7 +5113,6 @@ pub const NSIG = if (is_mips) 128 else 65;
pub const sigset_t = [1024 / 32]u32;
pub const all_mask: sigset_t = [_]u32{0xffffffff} ** @typeInfo(sigset_t).array.len;
pub const app_mask: sigset_t = [2]u32{ 0xfffffffc, 0x7fffffff } ++ [_]u32{0xffffffff} ** 30;
const k_sigaction_funcs = struct {
const handler = ?*align(1) const fn (i32) callconv(.c) void;

View File

@@ -720,16 +720,9 @@ pub fn raise(sig: u8) RaiseError!void {
}
if (native_os == .linux) {
var set: sigset_t = undefined;
// block application signals
sigprocmask(SIG.BLOCK, &linux.app_mask, &set);
const tid = linux.gettid();
const rc = linux.tkill(tid, sig);
// restore signal mask
sigprocmask(SIG.SETMASK, &set, null);
switch (errno(rc)) {
.SUCCESS => return,
else => |err| return unexpectedErrno(err),