From 3ffcdb9c3d0e84b3c9d2fa115f3db5d6c988c66c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alex=20R=C3=B8nne=20Petersen?= Date: Fri, 16 Oct 2026 21:21:21 +0200 Subject: [PATCH] std.c: fix MINSIGSTKSZ and SIGSTKSZ constants for openbsd --- lib/std/c.zig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/std/c.zig b/lib/std/c.zig index 0367ac6011577d51b92077a64a782158dbea4f63..3bb4378a5493308e1b68498c77c49d48429ccd01 100644 --- a/lib/std/c.zig +++ b/lib/std/c.zig @@ -9812,7 +9812,7 @@ pub const MINSIGSTKSZ = switch (native_os) { }, .illumos => 2048, .haiku, .netbsd => 8192, - .openbsd => 1 << openbsd.MAX_PAGE_SHIFT, + .openbsd => 3 << openbsd.MAX_PAGE_SHIFT, // https://github.com/SerenityOS/serenity/blob/ec492a1a0819e6239ea44156825c4ee7234ca3db/Kernel/API/POSIX/signal.h#L58 .serenity => 4096, else => {}, @@ -9822,7 +9822,7 @@ pub const SIGSTKSZ = switch (native_os) { .netbsd, .freebsd => MINSIGSTKSZ + 32768, .illumos => 8192, .haiku => 16384, - .openbsd => MINSIGSTKSZ + (1 << openbsd.MAX_PAGE_SHIFT) * 4, + .openbsd => MINSIGSTKSZ + (1 << openbsd.MAX_PAGE_SHIFT) * (if (openbsd.MAX_PAGE_SHIFT < 14) 4 else 2), // https://github.com/SerenityOS/serenity/blob/ec492a1a0819e6239ea44156825c4ee7234ca3db/Kernel/API/POSIX/signal.h#L59 .serenity => 32768, else => {}, -- 2.54.0