From 1ce6a7580b590773479cdb60d8194a589902dc8d Mon Sep 17 00:00:00 2001 From: "Dr. Chat" Date: Tue, 1 Dec 2015 16:49:27 -0600 Subject: [PATCH] Fix CaptureStackTrace with null out_stack_hash --- src/xenia/cpu/stack_walker_win.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/xenia/cpu/stack_walker_win.cc b/src/xenia/cpu/stack_walker_win.cc index 0902c167e..97c273ccd 100644 --- a/src/xenia/cpu/stack_walker_win.cc +++ b/src/xenia/cpu/stack_walker_win.cc @@ -134,7 +134,9 @@ class Win32StackWalker : public StackWalker { size_t CaptureStackTrace(uint64_t* frame_host_pcs, size_t frame_offset, size_t frame_count, uint64_t* out_stack_hash) override { - *out_stack_hash = 0; + if (out_stack_hash) { + *out_stack_hash = 0; + } // Simple method: captures just stack frame PC addresses, optionally // computing a whole-stack hash. ULONG back_trace_hash = 0;