This is the mail archive of the
cygwin-patches@cygwin.com
mailing list for the Cygwin project.
Re: Patch to allow trailing dots on managed mounts
- From: "Pierre A. Humblet" <pierre at phumblet dot no-ip dot org>
- To: cygwin-patches at cygwin dot com
- Date: Thu, 16 Dec 2004 11:56:39 -0500
- Subject: Re: Patch to allow trailing dots on managed mounts
- References: <41C1A1F4.CD3CC833@phumblet.no-ip.org>
- Reply-to: pierre dot humblet at ieee dot org
cgf wrote:
> Is it correct to assume that only fhandler_base::open cares about
>trailing dots?
Good point. This bring back memories.
The initial motivation was to fix problems introduced by the
use of NtCreateFile
http://www.cygwin.com/ml/cygwin/2004-04/msg01250.html
and there were successive changes
2004-04-30 Corinna Vinschen <corinna@vinschen.de>
* path.cc (normalize_posix_path): Remove trailing dots and spaces.
http://cygwin.com/ml/cygwin-patches/2004-q2/msg00053.html
2004-05-06 Pierre Humblet <pierre.humblet@ieee.org>
* path.cc (path_conv::check): Strip trailing dots and spaces and
return error if the final component had only dots and spaces.
(normalize_posix_path): Revert 2004-04-30.
However, as a side effect, checking the tail in :check
also cleanly fixed longstanding dormant issues with the path hash
and with chroot (at least).
So checking the tail in fhandler_base::open() is too late.
It should be done before exiting :check(), perhaps only in the
case where the path refers to a disk file, preferably
with little processing overhead.
Although it wasn't done before 2004/04, we should also make sure
(I have no free time for the moment) that nothing goes wrong
inside :check() while we lookup symbolic links.
Pierre