From 4cf2379f6176b704bb8648107beee9c896d1b133 Mon Sep 17 00:00:00 2001 From: Ralf Jung Date: Mon, 13 May 2019 11:34:11 +0200 Subject: [PATCH 1/2] Revert "use SecRandomCopyBytes on macOS in Miri" This reverts commit 54aefc6a2d076b74921a8d78c5d8c68c13bfa4a7. --- src/libstd/sys/unix/rand.rs | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/libstd/sys/unix/rand.rs b/src/libstd/sys/unix/rand.rs index e923b9aa29b01..77f1439e17b10 100644 --- a/src/libstd/sys/unix/rand.rs +++ b/src/libstd/sys/unix/rand.rs @@ -13,7 +13,6 @@ pub fn hashmap_random_keys() -> (u64, u64) { #[cfg(all(unix, not(target_os = "ios"), - not(all(target_os = "macos", miri)), not(target_os = "openbsd"), not(target_os = "freebsd"), not(target_os = "fuchsia")))] @@ -107,9 +106,7 @@ mod imp { // once per thread in `hashmap_random_keys`. Therefore `SecRandomCopyBytes` is // only used on iOS where direct access to `/dev/urandom` is blocked by the // sandbox. -// HACK: However, we do use this when running in Miri on macOS; intercepting this is much -// easier than intercepting accesses to /dev/urandom. -#[cfg(any(target_os = "ios", all(target_os = "macos", miri)))] +#[cfg(target_os = "ios")] mod imp { use crate::io; use crate::ptr; From 43207cada264796fe9307ded77e63751c1e0646a Mon Sep 17 00:00:00 2001 From: Ralf Jung Date: Mon, 13 May 2019 11:39:30 +0200 Subject: [PATCH 2/2] update miri --- src/tools/miri | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tools/miri b/src/tools/miri index 053aa694990a2..bc0c76d861a17 160000 --- a/src/tools/miri +++ b/src/tools/miri @@ -1 +1 @@ -Subproject commit 053aa694990a212ad8942dd72101ede23597c0e9 +Subproject commit bc0c76d861a178911f3f506196a7404eda1e690d