-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Add PipeNotAvailable error #21938
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add PipeNotAvailable error #21938
Conversation
The description of
From what I can tell, the most similar Linux error return for
I say this because attempting to open a pipe that actually doesn't exist on Windows returns So, my initial thoughts:
EDIT: Nothing seems off about the |
@squeek502 Could it be because of the const kind: Entry.Kind = blk: {
const attrs = dir_info.FileAttributes;
if (attrs & w.FILE_ATTRIBUTE_DIRECTORY != 0) break :blk .directory;
if (attrs & w.FILE_ATTRIBUTE_REPARSE_POINT != 0) break :blk .sym_link;
break :blk .file;
};
return Entry{
.name = name_wtf8,
.kind = kind,
}; For windows the kind can never actually be set to a .named_pipe in this Iterator, which I think should be possible. |
You're right that Windows can never return My last response was a bit convoluted, so here's some more actionable feedback:
|
Some ideas: |
In #21983, |
I'll update this to be |
LGTM; will wait for @squeek502 to sign off as well before merging. |
Should fix #21312
The unexpected
error.Unexpected NTSTATUS=0xc00000ac
is.PIPE_NOT_AVAILABLE
in windows. So this PR adds handling for it.I believe it is similar to PipeBusy, please correct me if I am mistaken.
The stat.zig program should now exit successfully.