[Issue 1004] New: Changed environment not passed to child process
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Sat Feb 24 04:12:27 PST 2007
http://d.puremagic.com/issues/show_bug.cgi?id=1004
Summary: Changed environment not passed to child process
Product: D
Version: 1.007
Platform: PC
OS/Version: Windows
Status: NEW
Severity: normal
Priority: P2
Component: Phobos
AssignedTo: bugzilla at digitalmars.com
ReportedBy: t_demmer at web.de
/*
Bug in spawnvp (and maybe others):
Only the initial environment is copied to the child process,
modifications get lost
Compile and run, type "SET",
you should see a line
YYY=xxxx
but you don't.
Works fine with gdc -mno-cygwin,
so I guess it is a phobos bug.
*/
import std.process;
extern(Windows) void SetEnvironmentVariableA(char *lpName, char *lpValue);
int
main(char[][] args){
SetEnvironmentVariableA(toStringz("YYY"),toStringz("xxxx"));
return spawnvp(0,"cmd.exe",args);
}
I did not find guidelines for setting values for Priority,
"Assign To", and "Cc", so sorry for bothering everyone...
--
More information about the Digitalmars-d-bugs
mailing list