mirror of
https://github.com/reactos/reactos.git
synced 2024-12-27 17:44:45 +00:00
Added 'Path' and 'windir' system environment variables
svn path=/trunk/; revision=1019
This commit is contained in:
parent
853d9d4ae2
commit
c0ad0d9b02
2 changed files with 41 additions and 5 deletions
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: init.c,v 1.14 2000/02/25 23:58:57 ekohl Exp $
|
/* $Id: init.c,v 1.15 2000/02/27 15:47:17 ekohl Exp $
|
||||||
*
|
*
|
||||||
* init.c - Session Manager initialization
|
* init.c - Session Manager initialization
|
||||||
*
|
*
|
||||||
|
@ -72,6 +72,9 @@ SmSetEnvironmentVariables (VOID)
|
||||||
{
|
{
|
||||||
UNICODE_STRING EnvVariable;
|
UNICODE_STRING EnvVariable;
|
||||||
UNICODE_STRING EnvValue;
|
UNICODE_STRING EnvValue;
|
||||||
|
UNICODE_STRING EnvExpandedValue;
|
||||||
|
ULONG ExpandedLength;
|
||||||
|
WCHAR ExpandBuffer[512];
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* The following environment variables are read from the registry.
|
* The following environment variables are read from the registry.
|
||||||
|
@ -114,6 +117,41 @@ SmSetEnvironmentVariables (VOID)
|
||||||
RtlSetEnvironmentVariable (&SmSystemEnvironment,
|
RtlSetEnvironmentVariable (&SmSystemEnvironment,
|
||||||
&EnvVariable,
|
&EnvVariable,
|
||||||
&EnvValue);
|
&EnvValue);
|
||||||
|
|
||||||
|
|
||||||
|
/* Set "Path = %SystemRoot%\system32;%SystemRoot%" */
|
||||||
|
RtlInitUnicodeString (&EnvVariable,
|
||||||
|
L"Path");
|
||||||
|
RtlInitUnicodeString (&EnvValue,
|
||||||
|
L"%SystemRoot%\\system32;%SystemRoot%");
|
||||||
|
EnvExpandedValue.Length = 0;
|
||||||
|
EnvExpandedValue.MaximumLength = 512 * sizeof(WCHAR);
|
||||||
|
EnvExpandedValue.Buffer = ExpandBuffer;
|
||||||
|
*ExpandBuffer = 0;
|
||||||
|
RtlExpandEnvironmentStrings_U (SmSystemEnvironment,
|
||||||
|
&EnvValue,
|
||||||
|
&EnvExpandedValue,
|
||||||
|
&ExpandedLength);
|
||||||
|
RtlSetEnvironmentVariable (&SmSystemEnvironment,
|
||||||
|
&EnvVariable,
|
||||||
|
&EnvExpandedValue);
|
||||||
|
|
||||||
|
/* Set "windir = %SystemRoot%" */
|
||||||
|
RtlInitUnicodeString (&EnvVariable,
|
||||||
|
L"windir");
|
||||||
|
RtlInitUnicodeString (&EnvValue,
|
||||||
|
L"%SystemRoot%");
|
||||||
|
EnvExpandedValue.Length = 0;
|
||||||
|
EnvExpandedValue.MaximumLength = 512 * sizeof(WCHAR);
|
||||||
|
EnvExpandedValue.Buffer = ExpandBuffer;
|
||||||
|
*ExpandBuffer = 0;
|
||||||
|
RtlExpandEnvironmentStrings_U (SmSystemEnvironment,
|
||||||
|
&EnvValue,
|
||||||
|
&EnvExpandedValue,
|
||||||
|
&ExpandedLength);
|
||||||
|
RtlSetEnvironmentVariable (&SmSystemEnvironment,
|
||||||
|
&EnvVariable,
|
||||||
|
&EnvExpandedValue);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: smss.c,v 1.6 2000/02/14 14:13:34 dwelch Exp $
|
/* $Id: smss.c,v 1.7 2000/02/27 15:47:17 ekohl Exp $
|
||||||
*
|
*
|
||||||
* smss.c - Session Manager
|
* smss.c - Session Manager
|
||||||
*
|
*
|
||||||
|
@ -69,10 +69,8 @@ PrintString (char* fmt,...)
|
||||||
void NtProcessStartup (PPEB Peb)
|
void NtProcessStartup (PPEB Peb)
|
||||||
{
|
{
|
||||||
HANDLE Children[2]; /* csrss, winlogon */
|
HANDLE Children[2]; /* csrss, winlogon */
|
||||||
|
|
||||||
DisplayString( L"Session Manager\n" );
|
|
||||||
|
|
||||||
PrintString ("Peb %x\n", Peb);
|
DisplayString( L"Session Manager\n" );
|
||||||
|
|
||||||
if (TRUE == InitSessionManager(Children))
|
if (TRUE == InitSessionManager(Children))
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue