This is the mail archive of the cygwin@sourceware.cygnus.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Bug Report File globbing in CMD shell


On Thu, 10 Jun 1999 15:17:33 -0400, cgf <cygwin@sourceware.cygnus.com>
wrote:

> ...>
>
> As I stated in another mail, the arguments to a cygwin program are not
> globbed unless an unquoted wildcard character is seen.  Cygwin does
> collapse a quoted backslash to a backslash, however.  It also leaves
> single backslashes, that do not quote anything "special", alone.
>...>

This isn't true in B20.1 as far as I can see. I'm interested in launching a
cygwin process from a non-cygwin app and it looks as if all single \s are
being stripped from the command line args. I'm guessing that this results
from globify-ing argv[1]..argv[argc-1] as in dcrt0.cc (build_argv). However
setting the CYGWIN environment to include noglob doesn't stop this (or maybe
I'm doing it wrong). I presume there is a way to force the allow_glob flag
in dcrt0.cc off, short of including build_argv in my program, but I haven't
found it yet.

(Whereas if the program is run from bash, the \s are stripped by bash before
my program's GetCommandLine() gets to see them).

A further syntactic collision occurs with execvp: it gets a file name
without spaces when called in a program run from bash, but a full /Program
Files/ought/to/be/bin name when run from cmd.exe: -> /Program: not found

I suppose this is all Digital's fault for introducing the / switch character
that DR and M$ copied - but at least they didn't accept anything as bizarre
as c:[Program Files.cygnus]cygnus.bat


--
Dirk Fieldhouse                 Logica UK Limited
fieldhouse@logica.com           75 Hampstead Road
c=gb;a=attmail;p=logica;        London NW1 2PL
o=LOGICA;ou1=UK;s=fieldhouse    UK
+44 (20) 7637 9111
not speaking for Logica




--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]