=?UTF-8?Q?Andr=C3=A9=20Hentschel=20?=: ntdll: Exit when we can' t map the shared user data.

Alexandre Julliard julliard at winehq.org
Wed Nov 28 14:14:06 CST 2012


Module: wine
Branch: master
Commit: 579f4f9da069441c269651177567f024a4df5ee2
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=579f4f9da069441c269651177567f024a4df5ee2

Author: André Hentschel <nerv at dawncrow.de>
Date:   Tue Nov 27 19:35:08 2012 +0100

ntdll: Exit when we can't map the shared user data.

---

 dlls/ntdll/thread.c |    9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)

diff --git a/dlls/ntdll/thread.c b/dlls/ntdll/thread.c
index 8f8fdcf..01a8026 100644
--- a/dlls/ntdll/thread.c
+++ b/dlls/ntdll/thread.c
@@ -200,6 +200,7 @@ HANDLE thread_init(void)
     SIZE_T size, info_size;
     HANDLE exe_file = 0;
     LARGE_INTEGER now;
+    NTSTATUS status;
     struct ntdll_thread_data *thread_data;
     static struct debug_info debug_info;  /* debug info for initial thread */
 
@@ -209,7 +210,13 @@ HANDLE thread_init(void)
 
     addr = (void *)0x7ffe0000;
     size = 0x10000;
-    NtAllocateVirtualMemory( NtCurrentProcess(), &addr, 0, &size, MEM_RESERVE|MEM_COMMIT, PAGE_READWRITE );
+    status = NtAllocateVirtualMemory( NtCurrentProcess(), &addr, 0, &size,
+                                      MEM_RESERVE|MEM_COMMIT, PAGE_READWRITE );
+    if (status)
+    {
+        MESSAGE( "wine: failed to map the shared user data: %08x\n", status );
+        exit(1);
+    }
     user_shared_data = addr;
 
     /* allocate and initialize the PEB */




More information about the wine-cvs mailing list