Skip to content
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 O_SEARCH to all platforms supported by libc crate #2374

Merged
merged 8 commits into from
Apr 21, 2024
Merged
1 change: 1 addition & 0 deletions changelog/2374.added.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Add `open` flag `O_SEARCH` to FreeBSD, solarish, Fuchsia
5 changes: 3 additions & 2 deletions src/fcntl.rs
Original file line number Diff line number Diff line change
Expand Up @@ -164,8 +164,9 @@ libc_bitflags!(
/// Similar to `O_DSYNC` but applies to `read`s instead.
#[cfg(any(target_os = "linux", netbsdlike))]
O_RSYNC;
/// Skip search permission checks.
#[cfg(target_os = "netbsd")]
/// Open directory for search only. Skip search permission checks on
/// later `openat()` calls using the obtained file descriptor.
#[cfg(any(target_os = "netbsd", freebsd, solarish, target_os = "fuchsia"))]
TheJonny marked this conversation as resolved.
Show resolved Hide resolved
O_SEARCH;
/// Open with a shared file lock.
#[cfg(any(bsd, target_os = "redox"))]
Expand Down