Module: wine Branch: master Commit: 3b85ab31a9179f46de12ab4cc8807eb8f701efc6 URL: https://gitlab.winehq.org/wine/wine/-/commit/3b85ab31a9179f46de12ab4cc8807eb...
Author: Alexandre Julliard julliard@winehq.org Date: Wed Feb 14 19:13:27 2024 +0100
ntdll: Move RtlUnwind to unwind.c.
---
dlls/ntdll/ntdll.spec | 2 +- dlls/ntdll/signal_arm.c | 19 ------------------- dlls/ntdll/signal_arm64.c | 18 ------------------ dlls/ntdll/signal_arm64ec.c | 19 ------------------- dlls/ntdll/signal_x86_64.c | 19 ------------------- dlls/ntdll/unwind.c | 24 ++++++++++++++++++++++++ 6 files changed, 25 insertions(+), 76 deletions(-)
diff --git a/dlls/ntdll/ntdll.spec b/dlls/ntdll/ntdll.spec index ccd270fee95..66995346e57 100644 --- a/dlls/ntdll/ntdll.spec +++ b/dlls/ntdll/ntdll.spec @@ -1513,7 +1513,7 @@ @ cdecl __isascii(long) @ cdecl __iscsym(long) @ cdecl __iscsymf(long) -@ stdcall -arch=arm __jump_unwind(ptr ptr) +@ stdcall -arch=arm __jump_unwind(ptr ptr) _local_unwind @ cdecl __toascii(long) @ cdecl -norelay -arch=i386 -ret64 _alldiv(int64 int64) @ cdecl -arch=i386 -norelay _alldvrm(int64 int64) diff --git a/dlls/ntdll/signal_arm.c b/dlls/ntdll/signal_arm.c index 12ab2860fa7..b07f91464a9 100644 --- a/dlls/ntdll/signal_arm.c +++ b/dlls/ntdll/signal_arm.c @@ -827,25 +827,6 @@ void WINAPI RtlUnwindEx( PVOID end_frame, PVOID target_ip, EXCEPTION_RECORD *rec }
-/*********************************************************************** - * RtlUnwind (NTDLL.@) - */ -void WINAPI RtlUnwind( void *frame, void *target_ip, EXCEPTION_RECORD *rec, void *retval ) -{ - CONTEXT context; - RtlUnwindEx( frame, target_ip, rec, retval, &context, NULL ); -} - - -/******************************************************************* - * __jump_unwind (NTDLL.@) - */ -void WINAPI __jump_unwind( void *frame, void *target_ip ) -{ - CONTEXT context; - RtlUnwindEx( frame, target_ip, NULL, NULL, &context, NULL ); -} - extern LONG __C_ExecuteExceptionFilter(PEXCEPTION_POINTERS ptrs, PVOID frame, PEXCEPTION_FILTER filter, PUCHAR nonvolatile); diff --git a/dlls/ntdll/signal_arm64.c b/dlls/ntdll/signal_arm64.c index 53d8cbfe304..0d6a88ed799 100644 --- a/dlls/ntdll/signal_arm64.c +++ b/dlls/ntdll/signal_arm64.c @@ -841,24 +841,6 @@ void WINAPI RtlUnwindEx( PVOID end_frame, PVOID target_ip, EXCEPTION_RECORD *rec }
-/*********************************************************************** - * RtlUnwind (NTDLL.@) - */ -void WINAPI RtlUnwind( void *frame, void *target_ip, EXCEPTION_RECORD *rec, void *retval ) -{ - CONTEXT context; - RtlUnwindEx( frame, target_ip, rec, retval, &context, NULL ); -} - -/******************************************************************* - * _local_unwind (NTDLL.@) - */ -void WINAPI _local_unwind( void *frame, void *target_ip ) -{ - CONTEXT context; - RtlUnwindEx( frame, target_ip, NULL, NULL, &context, NULL ); -} - extern LONG __C_ExecuteExceptionFilter(PEXCEPTION_POINTERS ptrs, PVOID frame, PEXCEPTION_FILTER filter, PUCHAR nonvolatile); diff --git a/dlls/ntdll/signal_arm64ec.c b/dlls/ntdll/signal_arm64ec.c index 8b4fd399c09..3f1869a644f 100644 --- a/dlls/ntdll/signal_arm64ec.c +++ b/dlls/ntdll/signal_arm64ec.c @@ -1792,25 +1792,6 @@ void WINAPI RtlUnwindEx( PVOID end_frame, PVOID target_ip, EXCEPTION_RECORD *rec }
-/******************************************************************* - * RtlUnwind (NTDLL.@) - */ -void WINAPI RtlUnwind( void *frame, void *target_ip, EXCEPTION_RECORD *rec, void *retval ) -{ - FIXME( "not implemented\n" ); -} - - -/******************************************************************* - * _local_unwind (NTDLL.@) - */ -void WINAPI _local_unwind( void *frame, void *target_ip ) -{ - CONTEXT context; - RtlUnwindEx( frame, target_ip, NULL, NULL, &context, NULL ); -} - - /******************************************************************* * __C_specific_handler (NTDLL.@) */ diff --git a/dlls/ntdll/signal_x86_64.c b/dlls/ntdll/signal_x86_64.c index 1dc4c9b75df..1396887bcc9 100644 --- a/dlls/ntdll/signal_x86_64.c +++ b/dlls/ntdll/signal_x86_64.c @@ -981,25 +981,6 @@ void WINAPI RtlUnwindEx( PVOID end_frame, PVOID target_ip, EXCEPTION_RECORD *rec }
-/******************************************************************* - * RtlUnwind (NTDLL.@) - */ -void WINAPI RtlUnwind( void *frame, void *target_ip, EXCEPTION_RECORD *rec, void *retval ) -{ - CONTEXT context; - RtlUnwindEx( frame, target_ip, rec, retval, &context, NULL ); -} - - -/******************************************************************* - * _local_unwind (NTDLL.@) - */ -void WINAPI _local_unwind( void *frame, void *target_ip ) -{ - CONTEXT context; - RtlUnwindEx( frame, target_ip, NULL, NULL, &context, NULL ); -} - /******************************************************************* * __C_specific_handler (NTDLL.@) */ diff --git a/dlls/ntdll/unwind.c b/dlls/ntdll/unwind.c index 42b119544fa..db95f12ebb2 100644 --- a/dlls/ntdll/unwind.c +++ b/dlls/ntdll/unwind.c @@ -1916,4 +1916,28 @@ BOOLEAN CDECL RtlAddFunctionTable( RUNTIME_FUNCTION *table, DWORD count, ULONG_P
#endif /* __x86_64__ */
+ +/*********************************************************************** + * Generic unwind functions + */ + + +/*********************************************************************** + * RtlUnwind (NTDLL.@) + */ +void WINAPI RtlUnwind( void *frame, void *target_ip, EXCEPTION_RECORD *rec, void *retval ) +{ + CONTEXT context; + RtlUnwindEx( frame, target_ip, rec, retval, &context, NULL ); +} + + +/******************************************************************* + * _local_unwind (NTDLL.@) + */ +void WINAPI _local_unwind( void *frame, void *target_ip ) +{ + RtlUnwind( frame, target_ip, NULL, NULL ); +} + #endif /* !__i386__ */