Alexandre Julliard : ntdll: Properly reset the stack environment at thread exit on ARM64.
Alexandre Julliard
julliard at winehq.org
Mon Jun 1 15:14:56 CDT 2020
Module: wine
Branch: master
Commit: 87fa906a84621295a76035d73dd6305c9cd2ea4a
URL: https://source.winehq.org/git/wine.git/?a=commit;h=87fa906a84621295a76035d73dd6305c9cd2ea4a
Author: Alexandre Julliard <julliard at winehq.org>
Date: Mon Jun 1 17:50:02 2020 +0200
ntdll: Properly reset the stack environment at thread exit on ARM64.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=49301
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/ntdll/unix/signal_arm64.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/dlls/ntdll/unix/signal_arm64.c b/dlls/ntdll/unix/signal_arm64.c
index 6a407c63d9..9cfb4eaa05 100644
--- a/dlls/ntdll/unix/signal_arm64.c
+++ b/dlls/ntdll/unix/signal_arm64.c
@@ -238,11 +238,13 @@ void signal_init_thread( TEB *teb )
extern void DECLSPEC_NORETURN call_thread_exit_func( int status, void (*func)(int), TEB *teb );
__ASM_GLOBAL_FUNC( call_thread_exit_func,
+ "stp x29, x30, [sp,#-16]!\n\t"
"ldr x3, [x2, #0x300]\n\t" /* arm64_thread_data()->exit_frame */
"str xzr, [x2, #0x300]\n\t"
"cbz x3, 1f\n\t"
"mov sp, x3\n"
- "1:\tblr x1" )
+ "1:\tldp x29, x30, [sp], #16\n\t"
+ "br x1" )
/***********************************************************************
* signal_exit_thread
More information about the wine-cvs
mailing list