This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFC] Fix problems related to Mingw/DJGPP file names containing colons


> From: "Pierre Muller" <pierre.muller@ics-cnrs.unistra.fr>
> Date: Sat, 13 Aug 2011 22:42:16 +0200
> 
> > What if the original name already includes quote characters?  That can
> > happen on Posix platforms.
>   You are right, but we are saved by the fact
> that colons are not allow on those platforms, isn't it?
> (otherwise all lists of directories like in the PATH
> environment variable would have a problem...)

borodin$ touch :
borodin$ ls -l :
-rw-r--r--  1 kettenis  wheel  0 Aug 13 23:16 :

Of course sane people wouldn't use it for exacty the reson you cite
above.

>   But there might be some 'exotic' file systems that allow
> both double-quotes and colons as valid characters in their
> filenames. In those cases, we would be in trouble...

borodin$ touch \"
borodin$ ls -l \"
-rw-r--r--  1 kettenis  wheel  0 Aug 13 23:20 "

So it's not that exotic.  Note however that I need to escape the
double-quote to prevent the shell from interpreting it as a quote.

Perhaps that's the solution here?  If you use "quotation" as well as
"escaping" you should be able to express anything you want on a
command line.


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