Rebase against a90592c8d29d3b145eada90c297405cbd8a9277f.

This commit is contained in:
Sebastian Lackner
2015-07-17 16:00:07 +02:00
parent 36e9309497
commit a37730ab0e
17 changed files with 70 additions and 1385 deletions

View File

@@ -1,44 +0,0 @@
From c16a0e4ac4e504a66a3337c0487da33100aab0a5 Mon Sep 17 00:00:00 2001
From: Sebastian Lackner <sebastian@fds-team.de>
Date: Wed, 25 Feb 2015 21:33:36 +0100
Subject: ntdll: Avoid deadlock by using _exit() in NtTerminateProcess.
Other threads are killed with SIGQUIT, so there is no guarantee that we can
terminate properly with exit().
---
dlls/ntdll/process.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/dlls/ntdll/process.c b/dlls/ntdll/process.c
index 3ac8d52..d20e107 100644
--- a/dlls/ntdll/process.c
+++ b/dlls/ntdll/process.c
@@ -21,11 +21,16 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
+#include "config.h"
+
#include <stdarg.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
+#ifdef HAVE_UNISTD_H
+# include <unistd.h>
+#endif
#include "ntstatus.h"
#define WIN32_NO_STATUS
@@ -60,7 +65,7 @@ NTSTATUS WINAPI NtTerminateProcess( HANDLE handle, LONG exit_code )
self = !ret && reply->self;
}
SERVER_END_REQ;
- if (self && handle) exit( exit_code );
+ if (self && handle) _exit( exit_code );
return ret;
}
--
2.3.0