delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2011/02/02/17:07:26

X-Recipient: archive-cygwin AT delorie DOT com
X-Spam-Check-By: sourceware.org
Date: Wed, 2 Feb 2011 23:07:02 +0100
From: Corinna Vinschen <corinna-cygwin AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: directories named '...' (dotdotdot) do not work
Message-ID: <20110202220702.GR2675@calimero.vinschen.de>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <loom DOT 20110201T203452-177 AT post DOT gmane DOT org> <20110202204556 DOT GL2675 AT calimero DOT vinschen DOT de> <4D49C4EB DOT 70204 AT redhat DOT com> <20110202212846 DOT GN2675 AT calimero DOT vinschen DOT de> <20110202213205 DOT GO2675 AT calimero DOT vinschen DOT de> <4D49D2C8 DOT 503 AT t-online DOT de>
MIME-Version: 1.0
In-Reply-To: <4D49D2C8.503@t-online.de>
User-Agent: Mutt/1.5.21 (2010-09-15)
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

On Feb  2 22:55, Christian Franke wrote:
> Corinna Vinschen wrote:
> >
> >Btw., the "..." directory is not recognized at all by cmd.exe.  If you
> >try to cd into it, it's simply ignored.  If you set the CWD to it
> >and start cmd, cmd thinks it is in the parent directory.  This occurs
> >on XP *and* W7.
> >
> 
> At least on XP cmd and others could not be run from a subdir below "...":
> 
> $ /bin/pwd
> /tmp/...
> 
> $ cmd.exe /c cd
> C:\cygwin\tmp
> 
> $ mkdir x
> 
> $ cd x
> 
> # /bin/pwd
> /tmp/.../x
> 
> # cmd.exe /c cd
> -bash: /cygdrive/c/WINDOWS/system32/cmd.exe: Not a directory
> 
> 
> Same for "....", ".....", ....
> 
> Different path checking in win32api layer and ntdll layer ?

Yes, definitely.  I explained that in
http://cygwin.com/ml/cygwin/2011-02/msg00078.html

On the Win32 level the path is massaged so that it follows DOS filename
conventions.  This is not done on the native NT level.  The long-path
prefix when used on the Win32 level (but only in the UNICODE API) disables
the DOSifying and just passes the path through to the native NT API.

> I would suggest to either quote or reject "..." in Cygwin.

Given that the path works fine except for starting an executable, and
given that starting an app works fine in Vista and later, there's no
reason to disallow the "..." path component entirely.  I'm not giving in
to the old DOS path conventions, unless there's absolutely no way around
it.


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019