4 #include <winpr/tchar.h>
5 #include <winpr/environment.h>
7 int TestEnvironmentMergeEnvironmentStrings(
int argc,
char* argv[])
12 LPTCH lpszEnvironmentBlock = NULL;
13 LPTCH lpsz2Merge =
"SHELL=123\0test=1\0test1=2\0DISPLAY=:77\0\0";
14 LPTCH lpszMergedEnvironmentBlock = NULL;
19 lpszEnvironmentBlock = GetEnvironmentStrings();
20 lpszMergedEnvironmentBlock = MergeEnvironmentStrings(lpszEnvironmentBlock, lpsz2Merge);
21 p = (TCHAR*)lpszMergedEnvironmentBlock;
30 FreeEnvironmentStrings(lpszMergedEnvironmentBlock);
31 FreeEnvironmentStrings(lpszEnvironmentBlock);