mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 01:55:19 +00:00
Fix GetVersion
svn path=/trunk/; revision=4547
This commit is contained in:
parent
bbe715ec28
commit
ff17fbcf89
2 changed files with 12 additions and 11 deletions
|
@ -1,4 +1,4 @@
|
|||
/* $Id: env.c,v 1.20 2003/02/12 00:39:31 hyperion Exp $
|
||||
/* $Id: env.c,v 1.21 2003/04/18 08:29:35 gvg Exp $
|
||||
*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS system libraries
|
||||
|
@ -309,11 +309,8 @@ GetVersionExA(
|
|||
gives extra work to RtlUnicodeStringToAnsiString, but spares us an
|
||||
RtlInitUnicodeString round
|
||||
*/
|
||||
sizeof(((LPOSVERSIONINFOW)NULL)->szCSDVersion) *
|
||||
sizeof(((LPOSVERSIONINFOW)NULL)->szCSDVersion[0]) -
|
||||
1,
|
||||
sizeof(((LPOSVERSIONINFOW)NULL)->szCSDVersion) *
|
||||
sizeof(((LPOSVERSIONINFOW)NULL)->szCSDVersion[0]),
|
||||
0,
|
||||
sizeof(((LPOSVERSIONINFOW)NULL)->szCSDVersion),
|
||||
oviVerInfo.szCSDVersion
|
||||
};
|
||||
|
||||
|
@ -321,9 +318,7 @@ GetVersionExA(
|
|||
ANSI_STRING strVerStr =
|
||||
{
|
||||
0,
|
||||
sizeof(((LPOSVERSIONINFOA)NULL)->szCSDVersion) *
|
||||
sizeof(((LPOSVERSIONINFOA)NULL)->szCSDVersion[0]) -
|
||||
1,
|
||||
sizeof(((LPOSVERSIONINFOA)NULL)->szCSDVersion),
|
||||
lpVersionInformation->szCSDVersion
|
||||
};
|
||||
|
||||
|
@ -355,10 +350,11 @@ GetVersionExA(
|
|||
/* null-terminate, just in case */
|
||||
oviVerInfo.szCSDVersion
|
||||
[
|
||||
sizeof(((LPOSVERSIONINFOW)NULL)->szCSDVersion) *
|
||||
sizeof(((LPOSVERSIONINFOW)NULL)->szCSDVersion) /
|
||||
sizeof(((LPOSVERSIONINFOW)NULL)->szCSDVersion[0]) -
|
||||
1
|
||||
] = 0;
|
||||
wstrVerStr.Length = wcslen(wstrVerStr.Buffer) * sizeof(WCHAR);
|
||||
|
||||
/* convert the version string */
|
||||
nErrCode = RtlUnicodeStringToAnsiString(&strVerStr, &wstrVerStr, FALSE);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $Id: startup.c,v 1.47 2002/12/08 15:57:40 robd Exp $
|
||||
/* $Id: startup.c,v 1.48 2003/04/18 08:29:35 gvg Exp $
|
||||
*
|
||||
* COPYRIGHT: See COPYING in the top level directory
|
||||
* PROJECT: ReactOS kernel
|
||||
|
@ -92,6 +92,11 @@ LdrInitializeThunk (ULONG Unknown1,
|
|||
ZwTerminateProcess(NtCurrentProcess(), STATUS_UNSUCCESSFUL);
|
||||
}
|
||||
|
||||
Peb->OSMajorVersion = 4;
|
||||
Peb->OSMinorVersion = 0;
|
||||
Peb->OSBuildNumber = 0;
|
||||
Peb->OSPlatformId = VER_PLATFORM_WIN32_NT;
|
||||
|
||||
NtGlobalFlag = Peb->NtGlobalFlag;
|
||||
|
||||
/* If MZ header exists */
|
||||
|
|
Loading…
Reference in a new issue