Overlay/app-emulation/wine/files/wine-1.7.39-gstreamer-v5-st...

39 lines
1.1 KiB
Diff

From b97783fd33b4d9897c149d7a14747aa4969bd9e9 Mon Sep 17 00:00:00 2001
From: Sebastian Lackner <sebastian@fds-team.de>
Date: Thu, 19 Mar 2015 07:56:04 +0100
Subject: Reapply various changes conflicting with Maarten Lankhorst's
gstreamer hack v5.
---
dlls/ntdll/thread.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/dlls/ntdll/thread.c b/dlls/ntdll/thread.c
index 1e7f231..cf0461d 100644
--- a/dlls/ntdll/thread.c
+++ b/dlls/ntdll/thread.c
@@ -461,6 +461,8 @@ static void exit_thread_common( int status )
static void *prev_teb;
TEB *teb;
#endif
+ shmlocal_t *shmlocal;
+ sigset_t sigset;
if (status) /* send the exit code to the server (0 is already the default) */
{
@@ -502,6 +504,11 @@ static void exit_thread_common( int status )
reap_thread(NtCurrentTeb());
#endif
+ sigemptyset( &sigset );
+ sigaddset( &sigset, SIGQUIT );
+ pthread_sigmask( SIG_BLOCK, &sigset, NULL );
+ if (interlocked_xchg_add( &nb_threads, -1 ) <= 1) _exit( status );
+
close( ntdll_get_thread_data()->wait_fd[0] );
close( ntdll_get_thread_data()->wait_fd[1] );
close( ntdll_get_thread_data()->reply_fd );
--
2.3.2