Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -475,7 +475,6 @@ set(ZIG_STAGE2_SOURCES
lib/std/os/linux.zig
lib/std/os/linux.zig
lib/std/os/linux/IoUring.zig
lib/std/os/linux/io_uring_sqe.zig
lib/std/os/linux/x86_64.zig
lib/std/os/linux/x86_64.zig
lib/std/os/windows.zig
Expand Down
2 changes: 1 addition & 1 deletion lib/std/fs.zig
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ pub fn cwd() Dir {
} else if (native_os == .wasi) {
return .{ .fd = std.options.wasiCwd() };
} else {
return .{ .fd = posix.AT.FDCWD };
return .{ .fd = posix.AT.fdcwd };
}
}

Expand Down
10 changes: 8 additions & 2 deletions lib/std/fs/Dir.zig
Original file line number Diff line number Diff line change
Expand Up @@ -2720,8 +2720,14 @@ pub fn statFile(self: Dir, sub_path: []const u8) StatFileError!Stat {
const rc = linux.statx(
self.fd,
&sub_path_c,
linux.AT.NO_AUTOMOUNT,
linux.STATX_TYPE | linux.STATX_MODE | linux.STATX_ATIME | linux.STATX_MTIME | linux.STATX_CTIME,
.{ .no_automount = true },
.{
.type = true,
.mode = true,
.atime = true,
.mtime = true,
.ctime = true,
},
&stx,
);

Expand Down
10 changes: 8 additions & 2 deletions lib/std/fs/File.zig
Original file line number Diff line number Diff line change
Expand Up @@ -564,8 +564,14 @@ pub fn stat(self: File) StatError!Stat {
const rc = linux.statx(
self.handle,
"",
linux.AT.EMPTY_PATH,
linux.STATX_TYPE | linux.STATX_MODE | linux.STATX_ATIME | linux.STATX_MTIME | linux.STATX_CTIME,
.{ .empty_path = true },
.{
.type = true,
.mode = true,
.atime = true,
.mtime = true,
.ctime = true,
},
&stx,
);

Expand Down
Loading
Loading