authorgravatar for dev@sgregoratto.meStephen Gregoratto <dev@sgregoratto.me> 2022-04-29 12:37:04+10:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2022-04-28 23:41:25-04:00
log2409041e627012baa770acfd21c407ef9ba46777
tree541cea417afd87d562f36da29e9dbbbfb0132920
parenta242906696a29b7ce251bd416bb995ca37e95d92

Seccomp fixups re: #10717

- Add type annotation for AUDIT.current. - Make unsupported archs a compile error.

1 files changed, 2 insertions(+), 2 deletions(-)

lib/std/os/linux.zig+2-2
...@@ -5421,7 +5421,7 @@ pub const AUDIT = struct {...@@ -5421,7 +5421,7 @@ pub const AUDIT = struct {
5421 const _64BIT = 0x80000000;5421 const _64BIT = 0x80000000;
5422 const _LE = 0x40000000;5422 const _LE = 0x40000000;
54235423
5424 pub const current = switch (native_arch) {5424 pub const current: AUDIT.ARCH = switch (native_arch) {
5425 .i386 => .I386,5425 .i386 => .I386,
5426 .x86_64 => .X86_64,5426 .x86_64 => .X86_64,
5427 .aarch64 => .AARCH64,5427 .aarch64 => .AARCH64,
...@@ -5433,7 +5433,7 @@ pub const AUDIT = struct {...@@ -5433,7 +5433,7 @@ pub const AUDIT = struct {
5433 .powerpc => .PPC,5433 .powerpc => .PPC,
5434 .powerpc64 => .PPC64,5434 .powerpc64 => .PPC64,
5435 .powerpc64le => .PPC64LE,5435 .powerpc64le => .PPC64LE,
5436 else => undefined,5436 else => @compileError("unsupported architecture"),
5437 };5437 };
54385438
5439 AARCH64 = toAudit(.aarch64),5439 AARCH64 = toAudit(.aarch64),