[PATCH 1/7] CMD : Correct support for cmd.exe /C string [bug 21927]
jason.edmeades at googlemail.com
Fri Sep 3 18:47:48 CDT 2010
The cmd.exe help is very explicit in when the new behaviour relating to
the removing of quotes when cmd.exe /C is used, and if any of them fail
then the behaviour reverts back to the old method, which is equivalent
to /S. This patch corrects that behaviour in that it enforces at least
one space, plus that the thing in quotes is an executable.
Note1: Tested manually on windows with procmon, windows does indeed do
the same as this patch, ie a double path/pathext search.
Note2: Tests in the patch are not good. This is because the only extra
tests you can execute rely on the ability to have an executable which
returns a specific string AND is identifiable as an executable. All
exe's under wine are dummy ones created in the build - you cant copy
e.g. cmd.exe to fred.exe and then launch it.
programs/cmd/batch.c | 2 +-
programs/cmd/tests/test_builtins.cmd | 4 ++
programs/cmd/tests/test_builtins.cmd.exp | 2 +
programs/cmd/wcmd.h | 2 +-
programs/cmd/wcmdmain.c | 59 +++++++++++++++++++-----------
5 files changed, 45 insertions(+), 24 deletions(-)
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 7488 bytes
Desc: not available
More information about the wine-patches