delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
X-SWARE-Spam-Status: | No, hits=-2.5 required=5.0 tests=AWL,BAYES_00,SPF_PASS |
X-Spam-Check-By: | sourceware.org |
Message-ID: | <4A6EDBC7.3050505@gmail.com> |
Date: | Tue, 28 Jul 2009 12:06:47 +0100 |
From: | Dave Korn <dave DOT korn DOT cygwin AT googlemail DOT com> |
User-Agent: | Thunderbird 2.0.0.17 (Windows/20080914) |
MIME-Version: | 1.0 |
To: | cygwin AT cygwin DOT com |
Subject: | Re: [1.7] bash UNC path bug? |
References: | <4A6EBFE9 DOT 7080007 AT shaddybaddah DOT name> |
In-Reply-To: | <4A6EBFE9.7080007@shaddybaddah.name> |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Id: | <cygwin.cygwin.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 |
Shaddy Baddah wrote: > Hi, > > bash... maybe cygpath, seems to be doing something weird: > > $ cygpath -u '\\someuncpath\someshare' > //someuncpath/someshare > $ echo `cygpath -u '\\someuncpath\someshare'` > /cygdrive/c/someuncpath/someshare > $ # what's going on here Dunno, but this sheds a little light into it: > $ set -x > > $ echo `cygpath -u '\\someuncpath\someshare'` > ++ cygpath -u '\someuncpath\someshare' > + echo /win/f/someuncpath/someshare > /win/f/someuncpath/someshare > > $ echo `echo '\\'` > ++ echo '\' > + echo '\' > \ > > $ How odd. Something stripped a level of escaping even though it's inside single quotes. It's not cygpath, so it's probably bash. It may be by design for all I know, something to do with being in back-ticks; I haven't RTFMd yet. You can work around it by doubling up the backslashes: $ echo `cygpath -u '\\\\someuncpath\\someshare'` //someuncpath/someshare cheers, DaveK -- 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
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |