Symbolic links

D

Derek Hyland

Hi

Does anybody know if it is possible to re-create unix
style symbolic links under the Windows 2K file system.
That is, have more than one directory entry pointing to
the one file.
I used to tweak the directory entry under DOS, and have
separate entries point to the same fat cluster, but it had
to be done manually, and of course, CHKDSK would "fix" the
problem :(
 
S

shura

NTFS supports so called "hard links".

WIN32 API of Win2K contains
CreateHardLink function

You can create hard link under NT too.
In this case you should use native API (ntdll.dll)
NtOpenFile() and NtSetInformationFile( ....,11 );

typedef struct _FILE_LINK_RENAME_INFORMATION { // Info Classes 10 and 11
BOOLEAN ReplaceIfExists;
HANDLE RootDirectory;
ULONG FileNameLength;
WCHAR FileName[1];
} FILE_LINK_INFORMATION, *PFILE_LINK_INFORMATION,
FILE_RENAME_INFORMATION, *PFILE_RENAME_INFORMATION;
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top