This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Symlink targets dereferenced when winsymlinks:native


On 18. 11. 2015 18:55, Corinna Vinschen wrote:
> On Nov 17 23:28, David Macek wrote:
>> Hi.
>>
>> I went through the UG looking for differences between regular Cygwin
>> symlinks and NTFS symlinks, but couldn't find this documented. It
>> seems that when using winsymlinks:native, the target path is first
>> dereferenced before storing it in the link.
> 
> It's a result of the native symlink being a Windows path.  The
> ultimate conversion from POSIX to Windows path dereferences all
> symlinks.

Should that behaviour stay? If not, I can send a patch for the UG.

>> That doesn't happed when
>> using regular symlink files. Is this behaviour intentional / known?
>>
>> If it matters, the use case is `ln -sf /proc/self/fd /dev/fd`.
> 
> It matters.  This is a bug in Cygwin, a missing test in fact.  It should
> never allow to create native symlinks to targets which only exist inside
> of Cygwin.  Consider that /proc/self/fd has no meaning to non-Cygwin
> processes at all.  Creating this symlink as native symlink doesn't make
> any sense, they should always be generated as Cygwin-only symlinks.
> 
> Thanks for the report, I'll apply a matching patch.

Cool.

-- 
David Macek

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]