Windows: hardlink support is broken on shared drives
Gavin Erry
gavinerry at erry.co.uk
Mon Aug 23 20:22:46 UTC 2010
All
I've been reading this thread with interest since I posted the problem on
the discussion list. Thanks for the fix - I will test it in the next build
of Hg. It seemed strange that GetFileInformationByHandle doesn't work too
well so I had a look (in C++ though)
It seems that you can get different results depending on how the handle was
created with the CreateFile function.
If I use GENERIC_READ or FILE_GENERIC_READ for the desired access in
CreateFile then I get an incorrect hardlink count.
Using FILE_READ_ATTRIBUTES | SYNCHRONIZE (which is a subset of
FILE_GENERIC_READ) then I get the correct hardlink count over the network.
This is all with Windows XP, and MS C++ (I don't do Python).
This is really a FYI - I have a bit of C++ code if anyone is interested, but
am not sure of the posting policy.
Gavin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial-devel/attachments/20100823/c075aefc/attachment.html>
More information about the Mercurial-devel
mailing list