Alexandre Julliard : kernel32: Fetch the system information only once the memory limits are correct.

Alexandre Julliard julliard at winehq.org
Thu Apr 4 13:54:15 CDT 2013


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

Author: Alexandre Julliard <julliard at winehq.org>
Date:   Thu Apr  4 13:01:04 2013 +0200

kernel32: Fetch the system information only once the memory limits are correct.

---

 dlls/kernel32/kernel_main.c |    2 ++
 dlls/kernel32/process.c     |    1 -
 2 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/dlls/kernel32/kernel_main.c b/dlls/kernel32/kernel_main.c
index cf548e3..13c01ed 100644
--- a/dlls/kernel32/kernel_main.c
+++ b/dlls/kernel32/kernel_main.c
@@ -83,6 +83,8 @@ static BOOL process_attach( HMODULE module )
 {
     RTL_USER_PROCESS_PARAMETERS *params = NtCurrentTeb()->Peb->ProcessParameters;
 
+    NtQuerySystemInformation( SystemBasicInformation, &system_info, sizeof(system_info), NULL );
+
     /* Setup registry locale information */
     LOCALE_InitRegistry();
 
diff --git a/dlls/kernel32/process.c b/dlls/kernel32/process.c
index 8fcf67b..93c0267 100644
--- a/dlls/kernel32/process.c
+++ b/dlls/kernel32/process.c
@@ -1147,7 +1147,6 @@ void CDECL __wine_kernel_init(void)
     setbuf(stderr,NULL);
     kernel32_handle = GetModuleHandleW(kernel32W);
     IsWow64Process( GetCurrentProcess(), &is_wow64 );
-    NtQuerySystemInformation( SystemBasicInformation, &system_info, sizeof(system_info), NULL );
 
     LOCALE_Init();
 




More information about the wine-cvs mailing list