Move the core environment parsing of environ_init into a new win32env_to_cygenv function.

win32env_to_cygwenv handles converting wchar to char and some other
minor taks.  Optionally it handles converting any paths in variables to
posix paths.

This will be useful for implementing /proc/<pid>/environ
This commit is contained in:
Erik M. Bray
2017-01-10 16:03:08 +01:00
committed by Corinna Vinschen
parent 387521976d
commit 7fd70a9706
2 changed files with 51 additions and 35 deletions

View File

@@ -45,4 +45,6 @@ extern "C" char __stdcall **cur_environ ();
char ** __reg3 build_env (const char * const *envp, PWCHAR &envblock,
int &envc, bool need_envblock, HANDLE new_token);
char ** __reg2 win32env_to_cygenv (PWCHAR rawenv, bool posify);
#define ENV_CVT -1