rbtcollins / fs_at

Filesystem 'at' implementations for Unix and Windows

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

enh: hardlink support

rbtcollins opened this issue · comments

https://learn.microsoft.com/en-us/windows-hardware/drivers/ddi/ntifs/nf-ntifs-ntsetinformationfile windows - FileLinkInformation can link to an existing file

RootDirectory permits safe construction of the link object itself, and the existing file handle is provided in the call to NtSetInformationFile, so this is safe.

For unix, linkat takes two dir handles, so similarly safe.

Duplicate of #9