authorgravatar for sid@scixor.comSiddharth Sinha <sid@scixor.com> 2026-04-05 20:18:39+05:30
committergravatar for squeek502@hotmail.comRyan Liptak <squeek502@hotmail.com> 2026-05-27 09:42:02+02:00
log284ab0ad86310df45ecc3887cb6ed2f8cf507e45
tree2499098738caea4771594acd6e9cff15d95f04b6
parent333724ff777a96c31416e7a64c7584c9ca3f54c5

std.Io.Uring: handle ReadOnlyFileSystem in dirOpenDir and dirRealPathFile

f4eecf8d7d added ROFS handling to openat but missed these two read-only callers, breaking compilation of any Io.Evented program.

1 files changed, 2 insertions(+), 0 deletions(-)

lib/std/Io/Uring.zig+2
...@@ -2739,6 +2739,7 @@ fn dirOpenDir(...@@ -2739,6 +2739,7 @@ fn dirOpenDir(
2739 error.FileBusy => return errnoBug(.TXTBSY),2739 error.FileBusy => return errnoBug(.TXTBSY),
2740 error.PathAlreadyExists => return errnoBug(.EXIST), // Not creating.2740 error.PathAlreadyExists => return errnoBug(.EXIST), // Not creating.
2741 error.OperationUnsupported => return errnoBug(.OPNOTSUPP), // No TMPFILE, no locks.2741 error.OperationUnsupported => return errnoBug(.OPNOTSUPP), // No TMPFILE, no locks.
2742 error.ReadOnlyFileSystem => return errnoBug(.ROFS), // Not creating.
2742 else => |e| return e,2743 else => |e| return e,
2743 },2744 },
2744 };2745 };
...@@ -3164,6 +3165,7 @@ fn dirRealPathFile(...@@ -3164,6 +3165,7 @@ fn dirRealPathFile(
3164 }, 0) catch |err| switch (err) {3165 }, 0) catch |err| switch (err) {
3165 error.WouldBlock => return errnoBug(.AGAIN),3166 error.WouldBlock => return errnoBug(.AGAIN),
3166 error.OperationUnsupported => return errnoBug(.OPNOTSUPP), // Not asking for locks.3167 error.OperationUnsupported => return errnoBug(.OPNOTSUPP), // Not asking for locks.
3168 error.ReadOnlyFileSystem => return errnoBug(.ROFS), // Not creating.
3167 else => |e| return e,3169 else => |e| return e,
3168 };3170 };
3169 defer ev.closeAsync(fd);3171 defer ev.closeAsync(fd);