Skip to content

Commit 665e9c6

Browse files
authored
Rollup merge of rust-lang#128967 - devnexen:get_path_fbsd_upd, r=joboet
std::fs::get_path freebsd update. what matters is we re doing the right things as doing sizeof, rather than passing KINFO_FILE_SIZE (only defined on intel architectures), the kernel making sure it matches the expectation in its side.
2 parents 3678036 + 65532e7 commit 665e9c6

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

library/std/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ miniz_oxide = { version = "0.7.0", optional = true, default-features = false }
3939
addr2line = { version = "0.22.0", optional = true, default-features = false }
4040

4141
[target.'cfg(not(all(windows, target_env = "msvc")))'.dependencies]
42-
libc = { version = "0.2.156", default-features = false, features = [
42+
libc = { version = "0.2.159", default-features = false, features = [
4343
'rustc-dep-of-std',
4444
], public = true }
4545

library/std/src/sys/pal/unix/fs.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1538,7 +1538,7 @@ impl fmt::Debug for File {
15381538
Some(PathBuf::from(OsString::from_vec(buf)))
15391539
}
15401540

1541-
#[cfg(all(target_os = "freebsd", target_arch = "x86_64"))]
1541+
#[cfg(target_os = "freebsd")]
15421542
fn get_path(fd: c_int) -> Option<PathBuf> {
15431543
let info = Box::<libc::kinfo_file>::new_zeroed();
15441544
let mut info = unsafe { info.assume_init() };
@@ -1566,7 +1566,7 @@ impl fmt::Debug for File {
15661566
#[cfg(not(any(
15671567
target_os = "linux",
15681568
target_os = "vxworks",
1569-
all(target_os = "freebsd", target_arch = "x86_64"),
1569+
target_os = "freebsd",
15701570
target_os = "netbsd",
15711571
target_os = "illumos",
15721572
target_os = "solaris",

0 commit comments

Comments
 (0)