diff options
| author | Alex Rønne Petersen <alex@alexrp.com> | 2024-08-21 15:49:09 +0200 |
|---|---|---|
| committer | Alex Rønne Petersen <alex@alexrp.com> | 2024-08-28 03:13:01 +0200 |
| commit | 34c64824038d829dfad200a66a20ee74cbe5c141 (patch) | |
| tree | e19f9413006330a100561a58da6a911b72bdbfd7 /lib | |
| parent | d702a21bbcef254f32a1c40498eb81c42c249f28 (diff) | |
| download | zig-34c64824038d829dfad200a66a20ee74cbe5c141.tar.gz zig-34c64824038d829dfad200a66a20ee74cbe5c141.zip | |
std.debug: Fix a bitness portability issue in walkStackWindows().
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/std/debug.zig | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/std/debug.zig b/lib/std/debug.zig index 4672f7ac06..ac02fbc6b8 100644 --- a/lib/std/debug.zig +++ b/lib/std/debug.zig @@ -789,7 +789,7 @@ pub noinline fn walkStackWindows(addresses: []usize, existing_context: ?*const w } var i: usize = 0; - var image_base: usize = undefined; + var image_base: windows.DWORD64 = undefined; var history_table: windows.UNWIND_HISTORY_TABLE = std.mem.zeroes(windows.UNWIND_HISTORY_TABLE); while (i < addresses.len) : (i += 1) { @@ -809,7 +809,7 @@ pub noinline fn walkStackWindows(addresses: []usize, existing_context: ?*const w ); } else { // leaf function - context.setIp(@as(*u64, @ptrFromInt(current_regs.sp)).*); + context.setIp(@as(*usize, @ptrFromInt(current_regs.sp)).*); context.setSp(current_regs.sp + @sizeOf(usize)); } |
