From: Charles Sandmann Newsgroups: comp.os.msdos.djgpp Subject: Re: gawk 3.1.1 DJGPP v2.04 on Windows 2000 Pro problem using system() function and LFNs Date: Thu, 30 Jan 2003 22:54:35 CST Organization: Rice University, Houston TX Lines: 36 Message-ID: <3e3a018b.sandmann@clio.rice.edu> References: <3e360683 DOT sandmann AT clio DOT rice DOT edu> <3e37507d DOT sandmann AT clio DOT rice DOT edu> NNTP-Posting-Host: clio.rice.edu X-Trace: joe.rice.edu 1043989068 12213 128.42.105.3 (31 Jan 2003 04:57:48 GMT) X-Complaints-To: abuse AT rice DOT edu NNTP-Posting-Date: 31 Jan 2003 04:57:48 GMT X-NewsEditor: ED-1.5.9 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com > I did try this but as Eli says in his posting, I don't > think that SHELL= should take parameters such as /C. It's just what you need to pass to cmd.exe to get it to execute the command after /C, then exit. > i.e., despite ver and echo %COMSPEC% saying that > we're using cmd.exe, DJGPP gawk's ENVIRON array > thinks that we're using COMMAND.COM Each DJGPP image is launched in a virtual DOS machine (see ntvdm.exe in your task list) which has a command.com loaded. So in a sense, you are under command.com in that environment. But CMD.EXE knows how to launch programs in the VDM and pass parameters to them. > Is it possible that there's a bug in DJGPP libc's > system() call? I've d/l'd a copy of Andrew's latest > version as per his post: it has a date of 24/01/02 > and the test shown above gives the same result. Anything's possible - I try things on my Win98 environment and Win2K and see if they act the same. The source is always available :-) > It looks as if Eli's comment that there is a bug > somewhere is correct. It could be in the way that > gawk obtains the information for its ENVIRON array, > but as I don't have the sources for the DJGPP v2.04 > gawk-3.1.1 I am not able to check this. Don't worry about the "command.com" thing - it's normal. Not handling spaces properly in passing - that might be a real problem...