fn mprotectLinux(addr: *anyopaque, len: usize, prot: c_int) callconv(.c) c_int
fn mprotectLinux(addr: *anyopaque, len: usize, prot: c_int) callconv(.c) c_int { const page_size = std.heap.pageSize(); const start = std.mem.alignBackward(usize, @intFromPtr(addr), page_size); const aligned_len = std.mem.alignForward(usize, len, page_size); return errno(std.os.linux.mprotect(@ptrFromInt(start), aligned_len, @bitCast(prot))); }