Commit 0a6f070f authored by Alexandre Julliard's avatar Alexandre Julliard

ntdll: Also set the dynamic environment strings in the initial parameters.

parent 528f9d32
......@@ -286,22 +286,7 @@ static void set_wow64_environment( WCHAR **env )
OBJECT_ATTRIBUTES attr;
UNICODE_STRING nameW;
HANDLE hkey;
SIZE_T size = 1024;
WCHAR *ptr, *val, *p;
for (;;)
{
if (!(ptr = RtlAllocateHeap( GetProcessHeap(), 0, size * sizeof(WCHAR) ))) break;
if (!unix_funcs->get_dynamic_environment( ptr, &size )) break;
RtlFreeHeap( GetProcessHeap(), 0, ptr );
}
for (p = ptr; *p; p += wcslen(p) + 1)
{
if ((val = wcschr( p, '=' ))) *val++ = 0;
set_env_var( env, p, val );
if (val) p = val;
}
RtlFreeHeap( GetProcessHeap(), 0, ptr );
WCHAR *val;
/* set the PROCESSOR_ARCHITECTURE variable */
......
......@@ -1607,7 +1607,6 @@ static struct unix_funcs unix_funcs =
ntdll_sin,
ntdll_sqrt,
ntdll_tan,
get_dynamic_environment,
get_unix_codepage_data,
get_locales,
virtual_release_address_space,
......
......@@ -99,7 +99,6 @@ extern LONGLONG CDECL fast_RtlGetSystemTimePrecise(void) DECLSPEC_HIDDEN;
extern NTSTATUS CDECL fast_wait_cv( RTL_CONDITION_VARIABLE *variable, const void *value,
const LARGE_INTEGER *timeout ) DECLSPEC_HIDDEN;
extern NTSTATUS CDECL get_dynamic_environment( WCHAR *env, SIZE_T *size ) DECLSPEC_HIDDEN;
extern USHORT * CDECL get_unix_codepage_data(void) DECLSPEC_HIDDEN;
extern void CDECL get_locales( WCHAR *sys, WCHAR *user ) DECLSPEC_HIDDEN;
extern void CDECL virtual_release_address_space(void) DECLSPEC_HIDDEN;
......
......@@ -27,7 +27,7 @@
struct _DISPATCHER_CONTEXT;
/* increment this when you change the function table */
#define NTDLL_UNIXLIB_VERSION 110
#define NTDLL_UNIXLIB_VERSION 111
struct unix_funcs
{
......@@ -71,7 +71,6 @@ struct unix_funcs
double (CDECL *tan)( double d );
/* environment functions */
NTSTATUS (CDECL *get_dynamic_environment)( WCHAR *env, SIZE_T *size );
USHORT * (CDECL *get_unix_codepage_data)(void);
void (CDECL *get_locales)( WCHAR *sys, WCHAR *user );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment