http://bugs.winehq.org/show_bug.cgi?id=33635
Bug #: 33635 Summary: wine cmd executes text inside comments as commands. Product: Wine Version: 1.5.29 Platform: x86-64 OS/Version: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: cmd AssignedTo: wine-bugs@winehq.org ReportedBy: loentar@gmail.com Classification: Unclassified
Created attachment 44521 --> http://bugs.winehq.org/attachment.cgi?id=44521 script to reproduce bug
When command script has "::" style comments and symbol "|" appear inside that comment wine cmd executes that text as commands (think it recognizes it as generic commands with pipe redirection).
For example if you create command script like that and start it you will see empty file "cmd_output", error "can't find another test" and started notepad:
:: some text that is ignored | dir >cmd_output | another test | notepad
Note when I replace "::" to rem, this error goes out.
http://bugs.winehq.org/show_bug.cgi?id=33635
--- Comment #1 from Dmitry Utkin loentar@gmail.com 2013-05-21 08:56:28 CDT --- Created attachment 44522 --> http://bugs.winehq.org/attachment.cgi?id=44522 screen output when wine_cmd_start_inside_comment.cmd is started
http://bugs.winehq.org/show_bug.cgi?id=33635
Jason Edmeades us@edmeades.me.uk changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW CC| |us@edmeades.me.uk Ever Confirmed|0 |1
--- Comment #2 from Jason Edmeades us@edmeades.me.uk 2013-06-01 18:20:26 CDT --- Many problems here around how wine identifies the labels themselves plus what characters terminate the labels. Attaching patch which is probably ready for submission - give it a go.
BTW You raised a number of cmd bugs (good! raise more!) - was there a specific program which hit them?
http://bugs.winehq.org/show_bug.cgi?id=33635
--- Comment #3 from Jason Edmeades us@edmeades.me.uk 2013-06-01 18:21:02 CDT --- Created attachment 44619 --> http://bugs.winehq.org/attachment.cgi?id=44619 Test patch
http://bugs.winehq.org/show_bug.cgi?id=33635
Jason Edmeades us@edmeades.me.uk changed:
What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|wine-bugs@winehq.org |us@edmeades.me.uk
http://bugs.winehq.org/show_bug.cgi?id=33635
--- Comment #4 from Dmitry Utkin loentar@gmail.com 2013-06-02 02:29:13 CDT --- I found this bug while tried to start SetEnv.cmd from Windows SDK v7.1 (v7.0a affected too).
There is a line:
:: Usage : Setenv [/Debug | /Release][/x86 | /x64 | /ia64 ][/vista | /xp | /2003 | /2008 | /win7][-h | /?]
and when it started under wine cmd it produce multiple error lines:
Can't recognize '/Release][/x86 ' as an internal or external command, or batch script. Can't recognize '/x64 ' as an internal or external command, or batch script.
and so on..
http://bugs.winehq.org/show_bug.cgi?id=33635
--- Comment #5 from Jason Edmeades us@edmeades.me.uk 2013-06-02 14:39:34 CDT --- Thanks, and the above patch does resolve that line :-)
http://bugs.winehq.org/show_bug.cgi?id=33635
--- Comment #6 from Jason Edmeades us@edmeades.me.uk 2013-06-02 17:05:45 CDT --- Patch submitted http://www.winehq.org/pipermail/wine-patches/2013-June/124542.html
http://bugs.winehq.org/show_bug.cgi?id=33635
Jason Edmeades us@edmeades.me.uk changed:
What |Removed |Added ---------------------------------------------------------------------------- Fixed by SHA1| |dc4dd0cb97c55698bccf204db10 | |e7b31901888a3 Status|NEW |RESOLVED Resolution| |FIXED
--- Comment #7 from Jason Edmeades us@edmeades.me.uk 2013-06-04 16:00:16 CDT --- Committed
http://bugs.winehq.org/show_bug.cgi?id=33635
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #8 from Alexandre Julliard julliard@winehq.org 2013-06-07 15:02:08 CDT --- Closing bugs fixed in 1.6-rc1.