#116 "/c" incorrectly replaced with "c:\" where it should not

Instruction_given
closed
nobody
MSYS (18)
5
2014-08-15
2009-04-21
No

Hello,
I have a problem where bash from MSYS incorrectly replaces occurrences of "/c" with "c:\":

boulan@AB ~
$ cmd.exe /c echo foobar
Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.

u:\>exit
exit

boulan@AB ~
$

Using process explorer, i can see that the command line for "cmd.exe" is the following:
c:\WINDOWS\system32\cmd.exe c:/ echo foobar

The expected result would be that "/c" is passed unchanged to cmd.exe

Another strange behaviour:

boulan@AB ~
$ cmd.exe /c echo foobar/c

boulan@AB ~

It is possible to work around the problem by using some complicated escape sequence:

boulan@AB ~
$ cmd.exe "\/c" echo foobar
foobar

boulan@AB ~
$

This problem is present with MSYS 1.0.10 and 1.0.11 snapshot

boulan@AB ~
$ uname -a
MINGW32_NT-5.1 AB 1.0.11(0.46/3/2) 2009-01-29 00:39 i686 Msys

boulan@AB ~
$ bash --version
GNU bash, version 3.1.0(1)-release (i686-pc-msys)
Copyright (C) 2005 Free Software Foundation, Inc.

Discussion

  • Earnie Boyd

    Earnie Boyd - 2009-04-21
    • labels: 380073 --> MSYS
     
  • Earnie Boyd

    Earnie Boyd - 2009-04-21

    $ cmd.exe //c echo foobar/c

    Read the files in /docs/msys/

     
  • Earnie Boyd

    Earnie Boyd - 2009-04-21
    • milestone: --> Instruction_given
    • status: open --> closed
     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks