Skip to content

Commit 1287eff

Browse files
committed
Don't try to use confstr in Miri
1 parent b62ee10 commit 1287eff

File tree

1 file changed

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

1 file changed

+2
-1
lines changed

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

+2-1
Original file line numberDiff line numberDiff line change
@@ -765,7 +765,8 @@ fn darwin_temp_dir() -> PathBuf {
765765
pub fn temp_dir() -> PathBuf {
766766
crate::env::var_os("TMPDIR").map(PathBuf::from).unwrap_or_else(|| {
767767
cfg_if::cfg_if! {
768-
if #[cfg(target_vendor = "apple")] {
768+
// FIXME: Support `confstr` in Miri.
769+
if #[cfg(all(target_vendor = "apple", not(miri)))] {
769770
darwin_temp_dir()
770771
} else if #[cfg(target_os = "android")] {
771772
PathBuf::from("/data/local/tmp")

0 commit comments

Comments
 (0)