MinGW32: Fix 13011e00: wrong safe esp variable in asm block

This commit is contained in:
Jonathan G Rennison
2021-04-14 20:54:24 +01:00
parent 205673715c
commit cb08d56add

View File

@@ -740,13 +740,13 @@ static void CDECL CustomAbort(int signal)
_safe_esp = (void *)(ctx.Rsp - 8); _safe_esp = (void *)(ctx.Rsp - 8);
# endif # endif
#else #else
void *safe_esp; void *safe_esp = nullptr;
# if defined(_MSC_VER) # if defined(_MSC_VER)
_asm { _asm {
mov safe_esp, esp mov safe_esp, esp
} }
# else # else
asm("movl %esp, _safe_esp"); asm("movl %%esp, %0" : "=rm" ( safe_esp ));
# endif # endif
_safe_esp = safe_esp; _safe_esp = safe_esp;
#endif #endif