From 107646d95d1ee8a10b68d6313fc98c69c665debb Mon Sep 17 00:00:00 2001 From: KISHAN GRIMOUT Date: Wed, 9 Jul 2014 13:41:43 +0200 Subject: [PATCH] fix windows 64bit build in mem_displayer.cpp --- code/nel/src/misc/mem_displayer.cpp | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/code/nel/src/misc/mem_displayer.cpp b/code/nel/src/misc/mem_displayer.cpp index fbc0c0236..6857bff64 100644 --- a/code/nel/src/misc/mem_displayer.cpp +++ b/code/nel/src/misc/mem_displayer.cpp @@ -282,12 +282,20 @@ static void displayCallStack (CLog *log) STACKFRAME callStack; ::ZeroMemory (&callStack, sizeof(callStack)); + +#ifdef NL_OS_WIN64 + callStack.AddrPC.Offset = context.Rip; + callStack.AddrStack.Offset = context.Rsp; + callStack.AddrFrame.Offset = context.Rbp; +#else + callStack.AddrPC.Offset = context.Eip; + callStack.AddrStack.Offset = context.Esp; + callStack.AddrFrame.Offset = context.Ebp; +#endif + callStack.AddrPC.Mode = AddrModeFlat; - callStack.AddrPC.Offset = context.Eip; callStack.AddrStack.Mode = AddrModeFlat; - callStack.AddrStack.Offset = context.Esp; callStack.AddrFrame.Mode = AddrModeFlat; - callStack.AddrFrame.Offset = context.Ebp; for (uint32 i = 0; ; i++) {