Implementation of RtlGetNtVersionNumbers.

oldstable
Ryan Cumming 2002-07-28 17:49:26 +00:00 committed by Alexandre Julliard
parent 44d3fd429e
commit 08be8f06cc
2 changed files with 29 additions and 1 deletions

View File

@ -385,7 +385,7 @@
@ stdcall RtlFreeUnicodeString(ptr) RtlFreeUnicodeString
@ stub RtlGenerate8dot3Name
@ stdcall RtlGetAce(ptr long ptr) RtlGetAce
@ stub RtlGetNtVersionNumbers
@ stdcall RtlGetNtVersionNumbers(ptr ptr ptr) RtlGetNtVersionNumbers
@ stub RtlGetVersion
@ stub RtlGetCallersAddress
@ stub RtlGetCompressionWorkSpaceSize

View File

@ -492,3 +492,31 @@ void WINAPI RtlAssert(LPVOID x1,LPVOID x2,DWORD x3, DWORD x4)
{
FIXME("(%p,%p,0x%08lx,0x%08lx),stub\n",x1,x2,x3,x4);
}
/******************************************************************************
* RtlGetNtVersionNumbers [NTDLL.@]
*
* Introduced in Windows XP (NT5.1)
*/
void WINAPI RtlGetNtVersionNumbers(LPDWORD major, LPDWORD minor, LPDWORD build)
{
OSVERSIONINFOEXW versionInfo;
versionInfo.dwOSVersionInfoSize = sizeof(OSVERSIONINFOEXW);
GetVersionExW((OSVERSIONINFOW*)&versionInfo);
if (major)
{
*major = versionInfo.dwMajorVersion;
}
if (minor)
{
*minor = versionInfo.dwMinorVersion;
}
if (build)
{
/* FIXME: Does anybody know the real formula? */
*build = (0xF0000000 | versionInfo.dwBuildNumber);
}
}