delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2021/05/18/16:01:56

X-Recipient: archive-cygwin AT delorie DOT com
DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 27D41385040D
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com;
s=default; t=1621368113;
bh=lJCTmhLLBLx57XZF9b86Or9gonkOLua2uY/AcSeptNo=;
h=Date:To:Subject:List-Id:List-Unsubscribe:List-Archive:List-Post:
List-Help:List-Subscribe:From:Reply-To:From;
b=XMeihMHeE0KYgtzZPqJWYl6m9bwKZIWuAoaMfrfakKo8MtIiI4OodSrML5MeLPGYH
jauuBjIgOUH/FNLqtIu6J5dxbi15FRHAUx+rY9VgC03giTGusi8zrDXNHw7WUcuTED
umy1m7DHLarjUhjRyYueHJbh515hF0F2b/qowMDI=
X-Original-To: cygwin AT cygwin DOT com
Delivered-To: cygwin AT cygwin DOT com
DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 87B3A385802D
Date: Tue, 18 May 2021 13:01:50 -0700 (PDT)
X-X-Sender: jeremyd AT resin DOT csoft DOT net
To: cygwin AT cygwin DOT com
Subject: Re: realpath issue with native[strict] symlinks
Message-ID: <alpine.BSO.2.21.2105181301130.14962@resin.csoft.net>
User-Agent: Alpine 2.21 (BSO 202 2017-01-01)
MIME-Version: 1.0
X-Spam-Status: No, score=-13.2 required=5.0 tests=BAYES_00, DKIM_SIGNED,
DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_LOW,
SPF_HELO_PASS, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on
server2.sourceware.org
X-BeenThere: cygwin AT cygwin DOT com
X-Mailman-Version: 2.1.29
List-Id: General Cygwin discussions and problem reports <cygwin.cygwin.com>
List-Archive: <https://cygwin.com/pipermail/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-request AT cygwin DOT com?subject=help>
List-Subscribe: <https://cygwin.com/mailman/listinfo/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=subscribe>
From: Jeremy Drake via Cygwin <cygwin AT cygwin DOT com>
Reply-To: Jeremy Drake <cygwin AT jdrake DOT com>
Sender: "Cygwin" <cygwin-bounces AT cygwin DOT com>

Sorry ,forgot subject

On Tue, 18 May 2021, Jeremy Drake wrote:

> > Sorry, but there's only this or that, not both.  Either we revert the
> > entire change, including the native shortcut stuff, or we do it
> > completely and fully, including handling virtual drives as symlinks.
>
> I had success with just the following change (of course comments would
> also need to be updated):
>
> diff --git a/winsup/cygwin/path.cc b/winsup/cygwin/path.cc
> index 4ebaf4dc6..53534b8b6 100644
> --- a/winsup/cygwin/path.cc
> +++ b/winsup/cygwin/path.cc
> @@ -3670,8 +3670,7 @@ restart:
>  		   somewhere else, thus, it's a symlink in POSIX speak. */
>  		if (upath.Length == 14)	/* \??\X:\ */
>  		  {
> -		    fileattr &= ~FILE_ATTRIBUTE_DIRECTORY;
> -		    path_flags |= PATH_SYMLINK;
> +		    goto file_not_symlink;
>  		  }
>  		/* For final paths differing in inner path components return
>  		   length as negative value.  This informs path_conv::check
>
> Treating mapped/subst drives as though they were not symlinks, without
> messing with intermedate symlinks.
>

-- 
Worst Response To A Crisis, 1985:
	From a readers' Q and A column in TV GUIDE: "If we get involved
	in a nuclear war, would the electromagnetic pulses from exploding
	bombs damage my videotapes?"

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

- Raw text -


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