This is the mail archive of the
mailing list for the Cygwin project.
Re: Incomplete environ when running MinGW apps?
Dave Korn wrote:
Out of curiosity, what's the problem with just using system("...") always?
I can't, because I need to redirect child I/O onto a socket, which
requires CreateProcess. The Unix code is (relatively) easy, but it's a
complete nightmare in Windoze. You have to use pipes as well as sockets,
it has to be multi-threaded, select doesn't work, and so on.
I can use 'system' occasionally, but then I have the issues of
forward/backslashes, extra backslashes, quotes, and so on. I haven't
really got to the bottom of this. With CreateProcess I at least have the
option to use /bin/sh, if it exists, which makes life a little easier
(particularly for quote characters).
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html