Skip to content

Commit 87f32bf

Browse files
committed
feat: OFlag::O_SEARCH for apple targets
1 parent e59c970 commit 87f32bf

File tree

2 files changed

+11
-1
lines changed

2 files changed

+11
-1
lines changed

changelog/2391.added.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Add `open` flag `O_SEARCH` to apple_targets

src/fcntl.rs

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,16 @@ libc_bitflags!(
166166
O_RSYNC;
167167
/// Open directory for search only. Skip search permission checks on
168168
/// later `openat()` calls using the obtained file descriptor.
169-
#[cfg(any(target_os = "netbsd", target_os = "freebsd", solarish, target_os = "fuchsia", target_os = "emscripten", target_os = "aix", target_os = "wasi"))]
169+
#[cfg(any(
170+
apple_targets,
171+
solarish,
172+
target_os = "netbsd",
173+
target_os = "freebsd",
174+
target_os = "fuchsia",
175+
target_os = "emscripten",
176+
target_os = "aix",
177+
target_os = "wasi"
178+
))]
170179
O_SEARCH;
171180
/// Open with a shared file lock.
172181
#[cfg(any(bsd, target_os = "redox"))]

0 commit comments

Comments
 (0)