| ... | ... | @@ -90,8 +90,8 @@ pub fn clock_getres(clock_id: i32, res: *timespec) errno_t { |
| 90 | 90 | return err; |
| 91 | 91 | } |
| 92 | 92 | res.* = .{ |
| 93 | | .tv_sec = @intCast(i64, ts / 1000000000), |
| 94 | | .tv_nsec = @intCast(isize, ts % 1000000000), |
| 93 | .tv_sec = @intCast(i64, ts / std.time.ns_per_s), |
| 94 | .tv_nsec = @intCast(isize, ts % std.time.ns_per_s), |
| 95 | 95 | }; |
| 96 | 96 | return 0; |
| 97 | 97 | } |
| ... | ... | @@ -103,8 +103,8 @@ pub fn clock_gettime(clock_id: i32, tp: *timespec) errno_t { |
| 103 | 103 | return err; |
| 104 | 104 | } |
| 105 | 105 | tp.* = .{ |
| 106 | | .tv_sec = @intCast(i64, ts / 1000000000), |
| 107 | | .tv_nsec = @intCast(isize, ts % 1000000000), |
| 106 | .tv_sec = @intCast(i64, ts / std.time.ns_per_s), |
| 107 | .tv_nsec = @intCast(isize, ts % std.time.ns_per_s), |
| 108 | 108 | }; |
| 109 | 109 | return 0; |
| 110 | 110 | } |