Skip to content

Commit e89bd8c

Browse files
authored
Rollup merge of #62414 - jethrogb:jb/sgx-uninit, r=Mark-Simulacrum
Remove last use of mem::uninitialized in SGX See #62397
2 parents cc453d9 + 7fb17d8 commit e89bd8c

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/libstd/sys/sgx/mod.rs

+1-3
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33
//! This module contains the facade (aka platform-specific) implementations of
44
//! OS level functionality for Fortanix SGX.
55
6-
#![allow(deprecated)]
7-
86
use crate::io::ErrorKind;
97
use crate::os::raw::c_char;
108
use crate::sync::atomic::{AtomicBool, Ordering};
@@ -142,7 +140,7 @@ pub unsafe extern "C" fn __rust_abort() {
142140
pub fn hashmap_random_keys() -> (u64, u64) {
143141
fn rdrand64() -> u64 {
144142
unsafe {
145-
let mut ret: u64 = crate::mem::uninitialized();
143+
let mut ret: u64 = 0;
146144
for _ in 0..10 {
147145
if crate::arch::x86_64::_rdrand64_step(&mut ret) == 1 {
148146
return ret;

0 commit comments

Comments
 (0)