about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorgeetanshjuneja <ronitjuneja2002@gmail.com>2025-01-13 11:19:41 +0530
committergeetanshjuneja <ronitjuneja2002@gmail.com>2025-01-13 11:19:41 +0530
commit9f13ac8e6bd2eb7ee622f82ced40bbf8c27df466 (patch)
tree5d2e89893a4c8feb79fff87bc2c3558365ec1c2b /src
parent78fdd593431ed362bf7dc4a694efe033438a8526 (diff)
downloadrust-9f13ac8e6bd2eb7ee622f82ced40bbf8c27df466.tar.gz
rust-9f13ac8e6bd2eb7ee622f82ced40bbf8c27df466.zip
Added deref_poiner_as in _NSGetExecutablePath
Diffstat (limited to 'src')
-rw-r--r--src/tools/miri/src/shims/unix/macos/foreign_items.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/tools/miri/src/shims/unix/macos/foreign_items.rs b/src/tools/miri/src/shims/unix/macos/foreign_items.rs
index 2afe0b5cd30..85c963774a1 100644
--- a/src/tools/miri/src/shims/unix/macos/foreign_items.rs
+++ b/src/tools/miri/src/shims/unix/macos/foreign_items.rs
@@ -120,7 +120,7 @@ pub trait EvalContextExt<'tcx>: crate::MiriInterpCxExt<'tcx> {
                 this.check_no_isolation("`_NSGetExecutablePath`")?;
 
                 let buf_ptr = this.read_pointer(buf)?;
-                let bufsize = this.deref_pointer(bufsize)?;
+                let bufsize = this.deref_pointer_as(bufsize, this.machine.layouts.u32)?;
 
                 // Using the host current_exe is a bit off, but consistent with Linux
                 // (where stdlib reads /proc/self/exe).