Skip to content

Commit b576dd2

Browse files
committed
Use ptr::invalid_mut for SGX image base
1 parent ec8c3d9 commit b576dd2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

library/std/src/sys_common/backtrace.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ pub fn output_filename(
218218
#[cfg(all(target_vendor = "fortanix", target_env = "sgx"))]
219219
pub fn set_image_base() {
220220
let image_base = crate::os::fortanix_sgx::mem::image_base();
221-
backtrace_rs::set_image_base(crate::ptr::from_exposed_addr_mut(image_base as _));
221+
backtrace_rs::set_image_base(crate::ptr::invalid_mut(image_base as _));
222222
}
223223

224224
#[cfg(not(all(target_vendor = "fortanix", target_env = "sgx")))]

0 commit comments

Comments
 (0)