diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2025-12-27 11:07:28 -0800 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2025-12-27 11:08:56 -0800 |
| commit | c0809c9b68ad33b9963ff3da1a6ad53ca2c8b6f3 (patch) | |
| tree | 6c4fa4c74f16dcbac8f64c4af18f10705bab5679 /lib/std/os/linux.zig | |
| parent | 10e72a8cad48e3e9e68f51d9e6769e30566029b1 (diff) | |
| download | zig-c0809c9b68ad33b9963ff3da1a6ad53ca2c8b6f3.tar.gz zig-c0809c9b68ad33b9963ff3da1a6ad53ca2c8b6f3.zip | |
std: add more timespec OMIT and NOW definitions
Diffstat (limited to 'lib/std/os/linux.zig')
| -rw-r--r-- | lib/std/os/linux.zig | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/lib/std/os/linux.zig b/lib/std/os/linux.zig index fb08830fcc..174ef64d95 100644 --- a/lib/std/os/linux.zig +++ b/lib/std/os/linux.zig @@ -8417,6 +8417,18 @@ pub const timezone = extern struct { pub const kernel_timespec = extern struct { sec: i64, nsec: i64, + + /// For use with `utimensat` and `futimens`. + pub const NOW: timespec = .{ + .sec = 0, + .nsec = 0x3fffffff, + }; + + /// For use with `utimensat` and `futimens`. + pub const OMIT: timespec = .{ + .sec = 0, + .nsec = 0x3ffffffe, + }; }; // https://github.com/ziglang/zig/issues/4726#issuecomment-2190337877 |
