Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Date: Thu, 1 Aug 2002 20:03:46 -0400 From: Christopher Faylor To: cygwin AT cygwin DOT com Subject: Re: bug: hard links to soft links do not work Message-ID: <20020802000346.GA373@redhat.com> Reply-To: cygwin AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com References: <5 DOT 1 DOT 0 DOT 14 DOT 2 DOT 20020801123520 DOT 01f97010 AT pop3 DOT cris DOT com> <20020801200325 DOT GC27689 AT redhat DOT com> <20020801210148 DOT GB29167 AT redhat DOT com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20020801210148.GB29167@redhat.com> User-Agent: Mutt/1.3.23.1i On Thu, Aug 01, 2002 at 05:01:48PM -0400, Christopher Faylor wrote: >Anyway, I will take a look at this. No need for a patch. I'll fix it, >where "fix" means make it work sensibly. I've checked in a patch. What I've done isn't consistent with linux but at least it does something sensible now: j:\tmp>touch x j:\tmp>ln -s x y j:\tmp>ln y z j:\tmp>ls -l ? -rw-rw-rw- 2 cgf None 0 Aug 1 19:56 x lrwxrwxrwx 1 cgf None 82 Aug 1 19:56 y -> x -rw-rw-rw- 2 cgf None 0 Aug 1 19:56 z Making it consistent with linux is difficult owing to the fact that there are at least two different types of symlinks in cygwin. Corinna pointed out to me in private email that we'd have to correctly detect which type of symlink we were attempting to link to and do the correct thing for each. For "new" symlinks, we'd have to add a .lnk extension. For "old" symlinks we wouldn't do that. This would mean propagating the info about the symlink type almost to the API level in cygwin. That is messy. Contrast that to the above two character source code change. No contest. cgf -- Please do not send me personal email with cygwin questions. Use the resources at http://cygwin.com/ . -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Bug reporting: http://cygwin.com/bugs.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/