| ... | @@ -2210,7 +2210,6 @@ pub const libc = struct { | ... | @@ -2210,7 +2210,6 @@ pub const libc = struct { |
| 2210 | /// https://pubs.opengroup.org/onlinepubs/9699919799.orig/functions/pthread_condattr_destroy.html | 2210 | /// https://pubs.opengroup.org/onlinepubs/9699919799.orig/functions/pthread_condattr_destroy.html |
| 2211 | pub extern fn pthread_condattr_destroy(attr: *pthread_condattr_t) c_int; | 2211 | pub extern fn pthread_condattr_destroy(attr: *pthread_condattr_t) c_int; |
| 2212 | | 2212 | |
| 2213 | | | |
| 2214 | /// int pthread_condattr_init(pthread_condattr_t *attr); | 2213 | /// int pthread_condattr_init(pthread_condattr_t *attr); |
| 2215 | /// https://pubs.opengroup.org/onlinepubs/9699919799.orig/functions/pthread_condattr_init.html | 2214 | /// https://pubs.opengroup.org/onlinepubs/9699919799.orig/functions/pthread_condattr_init.html |
| 2216 | pub extern fn pthread_condattr_init(attr: *pthread_condattr_t) c_int; | 2215 | pub extern fn pthread_condattr_init(attr: *pthread_condattr_t) c_int; |
| ... | @@ -2751,6 +2750,7 @@ pub const libc = struct { | ... | @@ -2751,6 +2750,7 @@ pub const libc = struct { |
| 2751 | pub extern fn sched_getaffinity(pid: pid_t, cpusetsize: usize, mask: *cpu_set_t) c_int; | 2750 | pub extern fn sched_getaffinity(pid: pid_t, cpusetsize: usize, mask: *cpu_set_t) c_int; |
| 2752 | pub extern fn getrandom(buf: [*]u8, size: usize, flags: c_uint) isize; | 2751 | pub extern fn getrandom(buf: [*]u8, size: usize, flags: c_uint) isize; |
| 2753 | pub extern fn flock(fd: c_int, op: c_int) c_int; | 2752 | pub extern fn flock(fd: c_int, op: c_int) c_int; |
| | 2753 | pub extern fn futimens(fd: c_int, times: *const [2]struct_timespec) c_int; |
| 2754 | }; | 2754 | }; |
| 2755 | | 2755 | |
| 2756 | pub const clock_t = c_long; | 2756 | pub const clock_t = c_long; |
| ... | @@ -3512,3 +3512,8 @@ pub fn flock(fd: c_int, op: c_int) !void { | ... | @@ -3512,3 +3512,8 @@ pub fn flock(fd: c_int, op: c_int) !void { |
| 3512 | if (rc == -1) return errno.fromInt(errno.fromLibC()); | 3512 | if (rc == -1) return errno.fromInt(errno.fromLibC()); |
| 3513 | std.debug.assert(rc == 0); | 3513 | std.debug.assert(rc == 0); |
| 3514 | } | 3514 | } |
| | 3515 | pub fn futimens(fd: c_int, times: [2]struct_timespec) !void { |
| | 3516 | const rc = libc.futimens(fd, &times); |
| | 3517 | if (rc == -1) return errno.fromInt(errno.fromLibC()); |
| | 3518 | std.debug.assert(rc == 0); |
| | 3519 | } |