Re: EMX runtime and command line arguments

Andreas Buening <[email protected]> Mon, 19 Jan 2004 11:07:48 +0100
Newsgroups gmane.comp.ide.emx.devel
Message-ID <[email protected]>
[email protected] wrote:

> IIRC: No. cmd.exe expects the argument of /c to be one argument.  Just like Unix shells
> take only one argument for -c.  Arguments beyond that argument have a different meaning.
> 
> IIRC: As the (de)quoting algorithm used by cmd.exe (at least for /c) differs from that one
> of other programs, emx.dll treats cmd.exe specially.

Sigh. Okay, I have an arbitrary string which is supposed to be a command
line for cmd. This line may contain arbitrary calls to arbitrary programs,
EMX as well as non-EMX programs, builtin commands and an arbitrary number
of special characters like &"'\%$;. The job has to be executed as a child
process, i.e., I have to use spawn*(). And, the command should be processed
as if the line had been entered on a cmd command line, and no quote or
backslash or whatever may (dis)appear magically.

How can I do this?


Bye,
Andreas