[PATCH 0/9] (resend) CMD command line parsing
Martin Wilck
mwilck at arcor.de
Mon Sep 19 18:51:10 CDT 2011
I am resending my patch series to improve CMD.EXE's command line parsing
The first series of patches had been sent on Aug. 30.
Remarks:
- I have kept my new tests in a separate file because I find it much
easier this way to locate problems (but I chose a less generic name).
- Please note the test on line 71 of test_cmdline.cmd.
The Windows documentation says
(http://technet.microsoft.com/de-de/library/cc771320%28WS.10%29.aspx):
"quotation marks are preserved only if ... You do not use any special
characters within the quotation marks (for example: & < > ( ) @ ^ | )".
In W2K8 and Vista the quotation marks are preserved even with '('
between them. Only XP correctly strips the quotes in this case.
I hope these patches are OK for inclusion in Wine now.
Regards
Martin
Martin Wilck (9):
cmd/tests: add tests for command line parsing
cmd: use GetCommandline() rather than argv
cmd/tests: fix TODOs in test output (GetCommandline())
cmd: improve parsing of quotes in command line
cmd/tests: fix TODOs in test output (quotes)
cmd: fix handling of special characters in command line
cmd/tests: adapt TODOs in test output (special characters)
cmd: fix parameter parsing of quotes and special chars
cmd/tests: adapt TODOs in test output (parameter passing)
programs/cmd/batch.c | 44 ++++--
programs/cmd/tests/rsrc.rc | 6 +
programs/cmd/tests/test_builtins.cmd.exp | 8 +-
programs/cmd/tests/test_cmdline.cmd | 158 +++++++++++++++++
programs/cmd/tests/test_cmdline.cmd.exp | 219 +++++++++++++++++++++++
programs/cmd/wcmdmain.c | 278 ++++++++++++------------------
6 files changed, 525 insertions(+), 188 deletions(-)
create mode 100755 programs/cmd/tests/test_cmdline.cmd
create mode 100755 programs/cmd/tests/test_cmdline.cmd.exp
--
1.7.3.4
More information about the wine-patches
mailing list