Author: cwittich
Date: Sun Jun 7 15:24:37 2009
New Revision: 41330
URL:
http://svn.reactos.org/svn/reactos?rev=41330&view=rev
Log:
fix msvcrt data winetests
Modified:
trunk/reactos/dll/win32/msvcrt/dllmain.c
Modified: trunk/reactos/dll/win32/msvcrt/dllmain.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msvcrt/dllmain.c…
==============================================================================
--- trunk/reactos/dll/win32/msvcrt/dllmain.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/msvcrt/dllmain.c [iso-8859-1] Sun Jun 7 15:24:37 2009
@@ -60,17 +60,19 @@
WINAPI
DllMain(PVOID hinstDll, ULONG dwReason, PVOID reserved)
{
+ OSVERSIONINFOW osvi;
switch (dwReason)
{
case DLL_PROCESS_ATTACH://1
/* initialize version info */
//DPRINT1("Process Attach %d\n", nAttachCount);
//DPRINT1("Process Attach\n");
- _osver = GetVersion();
- _winmajor = (_osver >> 8) & 0xFF;
- _winminor = _osver & 0xFF;
- _winver = (_winmajor << 8) + _winminor;
- _osver = (_osver >> 16) & 0xFFFF;
+ osvi.dwOSVersionInfoSize = sizeof(OSVERSIONINFOW);
+ GetVersionExW( &osvi );
+ _winver = (osvi.dwMajorVersion << 8) | osvi.dwMinorVersion;
+ _winmajor = osvi.dwMajorVersion;
+ _winminor = osvi.dwMinorVersion;
+ _osver = osvi.dwBuildNumber;
hHeap = HeapCreate(0, 100000, 0);
if (hHeap == NULL)
return FALSE;