[perl-python] a program to delete duplicate files
Christos TZOTZIOY Georgiou
tzot at sil-tec.gr
Fri Mar 11 09:30:11 EST 2005
On Fri, 11 Mar 2005 01:24:59 +0100, rumours say that Patrick Useldinger
<pu.news.001 at gmail.com> might have written:
>> Have you found any way to test if two files on NTFS are hard linked without
>> opening them first to get a file handle?
>
>No. And even then, I wouldn't know how to find out.
MSDN is our friend for Windows stuff.
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/fileio/base/createhardlink.asp
and then
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/fileio/base/getfileinformationbyhandle.asp
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/fileio/base/by_handle_file_information_str.asp
The relevant parts from this last page:
st_dev <-> dwVolumeSerialNumber
st_ino <-> (nFileIndexHigh, nFileIndexLow)
--
TZOTZIOY, I speak England very best.
"Be strict when sending and tolerant when receiving." (from RFC1958)
I really should keep that in mind when talking with people, actually...
More information about the Python-list
mailing list