On 07 February 2008 18:25, Paul Leder wrote: > 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).
Out of curiosity, what's the problem with just using popen("...") always? cheers, DaveK -- Can't think of a witty .sigline today.... -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/