﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	severity	resolution	keywords	cc
170	SafeDosStartSession only passed first environment variable to child	guest	bird	"Using libc062 and the highmem safe version (via #include <os2safe.h>) of DosStartSession only the very first environment variable is passed to the child. I will attach a test program that is broken when compiled with
   gcc -Zhigh-mem -Zomf -Zexe DSS_test.c
The shell that is opened only contains 
   [C:\] set
   WP_OBJHANDLE=164325
   PATH=
   COMSPEC=C:\OS2\CMD.EXE
in the environment.

I believe that this is in part due to the use of str*() functions to work with the STARTDATA.Environment object that consists of many \0 separated strings. Specifically, this

   l4 = strlen((const char *)Environment) + 1;

would better be written like this

   char *p = Environment;
   while (*p) {
     p += strlen(p) + 1;
   }
   l4 = (int)(p - Environment);
"	defect	closed	normal	libc-0.6.3	libc	0.6	normal	fixed		mozilla@…
