| ... | @@ -5823,7 +5823,8 @@ pub fn ppoll(fds: []pollfd, timeout: ?*const timespec, mask: ?*const sigset_t) P | ... | @@ -5823,7 +5823,8 @@ pub fn ppoll(fds: []pollfd, timeout: ?*const timespec, mask: ?*const sigset_t) P |
| 5823 | ts_ptr = &ts; | 5823 | ts_ptr = &ts; |
| 5824 | ts = timeout_ns.*; | 5824 | ts = timeout_ns.*; |
| 5825 | } | 5825 | } |
| 5826 | const rc = system.ppoll(fds.ptr, fds.len, ts_ptr, mask); | 5826 | const fds_count = math.cast(nfds_t, fds.len) catch return error.SystemResources; |
| | 5827 | const rc = system.ppoll(fds.ptr, fds_count, ts_ptr, mask); |
| 5827 | switch (errno(rc)) { | 5828 | switch (errno(rc)) { |
| 5828 | .SUCCESS => return @intCast(usize, rc), | 5829 | .SUCCESS => return @intCast(usize, rc), |
| 5829 | .FAULT => unreachable, | 5830 | .FAULT => unreachable, |