From 567bb525f83c5ec1865b17593aa73a62ebc31170 Mon Sep 17 00:00:00 2001 From: "Dr. Chat" Date: Sun, 5 Jul 2015 15:41:47 -0500 Subject: [PATCH] Fix incorrectly getting the exe address --- src/xenia/cpu/xex_module.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/xenia/cpu/xex_module.cc b/src/xenia/cpu/xex_module.cc index f3f36951b..e800829a0 100644 --- a/src/xenia/cpu/xex_module.cc +++ b/src/xenia/cpu/xex_module.cc @@ -297,11 +297,11 @@ bool XexModule::Load(const std::string& name, const std::string& path, bool XexModule::Unload() { // Just deallocate the memory occupied by the exe - uint32_t exe_address = 0; + xe::be* exe_address = 0; GetOptHeader(XEX_HEADER_IMAGE_BASE_ADDRESS, &exe_address); assert_not_zero(exe_address); - memory()->LookupHeap(exe_address)->Release(exe_address); + memory()->LookupHeap(*exe_address)->Release(*exe_address); assert_not_null(xex_header_); // Unloading a module that wasn't loaded? delete[] xex_header_;