Module: wine Branch: master Commit: cfd09b09675a9365f8f876b77947912e8f832861 URL: http://source.winehq.org/git/wine.git/?a=commit;h=cfd09b09675a9365f8f876b779...
Author: Sebastian Lackner sebastian@fds-team.de Date: Sun Jun 22 03:27:31 2014 +0200
ntdll: Fix leaking activation context when terminating via exit_thread(). (Valgrind).
---
dlls/kernel32/thread.c | 1 - dlls/ntdll/thread.c | 1 + 2 files changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/kernel32/thread.c b/dlls/kernel32/thread.c index 5d87cdd..5b9a683 100644 --- a/dlls/kernel32/thread.c +++ b/dlls/kernel32/thread.c @@ -150,7 +150,6 @@ HANDLE WINAPI OpenThread( DWORD dwDesiredAccess, BOOL bInheritHandle, DWORD dwTh */ void WINAPI ExitThread( DWORD code ) /* [in] Exit code for this thread */ { - RtlFreeThreadActivationContextStack(); RtlExitUserThread( code ); }
diff --git a/dlls/ntdll/thread.c b/dlls/ntdll/thread.c index 56ea033..6e2ed67 100644 --- a/dlls/ntdll/thread.c +++ b/dlls/ntdll/thread.c @@ -376,6 +376,7 @@ void exit_thread( int status ) }
LdrShutdownThread(); + RtlFreeThreadActivationContextStack();
pthread_sigmask( SIG_BLOCK, &server_block_set, NULL );