Skip to content

Commit b6af0c4

Browse files
committed
std::fs::DirEntry.metadata(): prefer use of lstat() on Emscripten
Align it with musl, which also prefers using lstat() here.
1 parent ef58e8b commit b6af0c4

File tree

1 file changed

+1
-8
lines changed
  • library/std/src/sys/pal/unix

1 file changed

+1
-8
lines changed

Diff for: library/std/src/sys/pal/unix/fs.rs

+1-8
Original file line numberDiff line numberDiff line change
@@ -8,16 +8,11 @@ mod tests;
88
use libc::c_char;
99
#[cfg(any(
1010
all(target_os = "linux", not(target_env = "musl")),
11-
target_os = "emscripten",
1211
target_os = "android",
1312
target_os = "hurd"
1413
))]
1514
use libc::dirfd;
16-
#[cfg(any(
17-
all(target_os = "linux", not(target_env = "musl")),
18-
target_os = "emscripten",
19-
target_os = "hurd"
20-
))]
15+
#[cfg(any(all(target_os = "linux", not(target_env = "musl")), target_os = "hurd"))]
2116
use libc::fstatat64;
2217
#[cfg(any(
2318
target_os = "android",
@@ -896,7 +891,6 @@ impl DirEntry {
896891
#[cfg(all(
897892
any(
898893
all(target_os = "linux", not(target_env = "musl")),
899-
target_os = "emscripten",
900894
target_os = "android",
901895
target_os = "hurd"
902896
),
@@ -925,7 +919,6 @@ impl DirEntry {
925919
#[cfg(any(
926920
not(any(
927921
all(target_os = "linux", not(target_env = "musl")),
928-
target_os = "emscripten",
929922
target_os = "android",
930923
target_os = "hurd",
931924
)),

0 commit comments

Comments
 (0)