From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 44352 invoked by alias); 26 Nov 2016 01:42:19 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 44321 invoked by uid 89); 26 Nov 2016 01:42:18 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=1.8 required=5.0 tests=BAYES_50,KAM_LAZY_DOMAIN_SECURITY autolearn=no version=3.3.2 spammy=Notice, H*MI:solutions, mkdir, H*x:Service X-HELO: smtp.tt-solutions.com Received: from sunset.tt-solutions.com (HELO smtp.tt-solutions.com) (82.240.17.225) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sat, 26 Nov 2016 01:42:08 +0000 Received: from [192.168.17.86] (helo=Twilight) by smtp.tt-solutions.com with esmtps (TLS1.0:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.87) (envelope-from ) id 1cAS0E-000087-Ba for cygwin@cygwin.com; Sat, 26 Nov 2016 02:42:06 +0100 Date: Sun, 27 Nov 2016 01:20:00 -0000 From: Vadim Zeitlin Subject: Bug in cygpath -a handling of leading ".//" To: cygwin@cygwin.com MIME-Version: 1.0 Content-Type: MULTIPART/SIGNED; protocol="application/pgp-signature"; micalg=pgp-sha1; BOUNDARY="27031793-41-1480124526=:7124" Message-Id: X-SW-Source: 2016-11/txt/msg00299.txt.bz2 --27031793-41-1480124526=:7124 Content-Type: TEXT/PLAIN; CHARSET=US-ASCII Content-Disposition: INLINE Content-length: 1129 Hello, I seem to have a special talent for finding problems related to the handling of doubled consecutive slashes in cygpath, as 5 years after posting my previous bug report on this topic (see http://sourceware.org/ml/cygwin/2011-06/msg00212.html), I have another one which is also best shown with an example obtained with the latest Cygwin 2.6.0 version under Windows 7: [~]% cd /tmp [/tmp]% mkdir dir [/tmp]% cd $_ [/tmp/dir]% cygpath -a ../dir /tmp/dir [/tmp/dir]% cygpath -a ./../dir /tmp/dir [/tmp/dir]% cygpath -a .//../dir /tmp/dir/dir The last one is, of course, incorrect, as it should still output /tmp/dir. Notice that the problem doesn't happen if "-am" or "-aw" is used, only for "-a" on its own, so it does have a simple workaround: realpath can be used instead. But I still wanted to report it in the hope that it might at least help somebody else if they run into it (it took me quite some time to realize that the bug wasn't in my own makefile but rather in cygpath itself...). Please let me know if you'd like me to provide any further information and thanks in advance for looking at this, VZ --27031793-41-1480124526=:7124 Content-Type: APPLICATION/PGP-SIGNATURE Content-length: 196 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (MingW32) iEYEABECAAYFAlg46G4ACgkQBupB3k9sHob3WACfQqBnl3KDtr+AiZ+2EpRrwT+1 AKsAoJwFPdpsGQfiyk7g+ZFj+uWVhgDr =91/+ -----END PGP SIGNATURE----- --27031793-41-1480124526=:7124--