| ... | ... | @@ -820,8 +820,7 @@ pub fn sigaction(sig: u6, noalias act: *const Sigaction, noalias oact: ?*Sigacti |
| 820 | 820 | @memcpy(@ptrCast([*]u8, &ksa.mask), @ptrCast([*]const u8, &act.mask), ksa_mask_size); |
| 821 | 821 | const result = switch (builtin.arch) { |
| 822 | 822 | // The sparc version of rt_sigaction needs the restorer function to be passed as an argument too. |
| 823 | | .sparc, .sparcv9 => syscall5(.rt_sigaction, sig, |
| 824 | | @ptrToInt(&ksa), @ptrToInt(&ksa_old), @ptrToInt(ksa.restorer), ksa_mask_size), |
| 823 | .sparc, .sparcv9 => syscall5(.rt_sigaction, sig, @ptrToInt(&ksa), @ptrToInt(&ksa_old), @ptrToInt(ksa.restorer), ksa_mask_size), |
| 825 | 824 | else => syscall4(.rt_sigaction, sig, @ptrToInt(&ksa), @ptrToInt(&ksa_old), ksa_mask_size), |
| 826 | 825 | }; |
| 827 | 826 | const err = getErrno(result); |
| ... | ... | @@ -1280,13 +1279,7 @@ pub fn setrlimit(resource: rlimit_resource, rlim: *const rlimit) usize { |
| 1280 | 1279 | } |
| 1281 | 1280 | |
| 1282 | 1281 | pub fn prlimit(pid: pid_t, resource: rlimit_resource, new_limit: ?*const rlimit, old_limit: ?*rlimit) usize { |
| 1283 | | return syscall4( |
| 1284 | | .prlimit64, |
| 1285 | | @bitCast(usize, @as(isize, pid)), |
| 1286 | | @bitCast(usize, @as(isize, @enumToInt(resource))), |
| 1287 | | @ptrToInt(new_limit), |
| 1288 | | @ptrToInt(old_limit) |
| 1289 | | ); |
| 1282 | return syscall4(.prlimit64, @bitCast(usize, @as(isize, pid)), @bitCast(usize, @as(isize, @enumToInt(resource))), @ptrToInt(new_limit), @ptrToInt(old_limit)); |
| 1290 | 1283 | } |
| 1291 | 1284 | |
| 1292 | 1285 | test "" { |