| ... | ... | @@ -3313,6 +3313,14 @@ pub const W = struct { |
| 3313 | 3313 | } |
| 3314 | 3314 | }; |
| 3315 | 3315 | |
| 3316 | pub const SEEK = struct { |
| 3317 | pub const SET = 0; |
| 3318 | pub const CUR = 1; |
| 3319 | pub const END = 2; |
| 3320 | pub const DATA = 3; |
| 3321 | pub const HOLE = 4; |
| 3322 | }; |
| 3323 | |
| 3316 | 3324 | pub fn getpid() pid_t { |
| 3317 | 3325 | return libc.getpid(); |
| 3318 | 3326 | } |
| ... | ... | @@ -3700,3 +3708,8 @@ pub fn unlinkat(fd: c_int, name: [*:0]const u8, flag: c_int) !void { |
| 3700 | 3708 | if (rc == -1) return errno.fromInt(errno.fromLibC()); |
| 3701 | 3709 | std.debug.assert(rc == 0); |
| 3702 | 3710 | } |
| 3711 | pub fn lseek(fd: c_int, offset: off_t, whence: c_int) !void { |
| 3712 | const rc = libc.lseek(fd, offset, whence); |
| 3713 | if (rc == -1) return errno.fromInt(errno.fromLibC()); |
| 3714 | std.debug.assert(rc >= 0); |
| 3715 | } |