Subject: Ftp-WG: I _nearly_ had a 'unique' fact.

From: Alun Jones <[email-masked]>
Date: Tue, 10 Aug 1999 08:06:31 -0400

In my search for a possible 'unique' fact, I went into the documentation
today and found a nice little structure, BY_HANDLE_FILE_INFORMATION, which
contains fields "dwVolumeSerialNumber", "nFileIndexHigh" and
"nFileIndexLow", and the documentation says of nFileIndex{High,Low}:

"This identifier and the volume serial number uniquely identify a file...
An application can use this identifier and the volume serial number to
determine whether two handles refer to the same file."

Home free, I thought... until I checked further.  The only way to fill this
structure is to call GetFileInformationByHandle, which requires that you
open the file itself.  <sigh>  And just in case you were thinking "oh well,
it just makes the unique fact expensive to generate, reading further in the
documentation of nFileIndex{High,Low} we get:

"This number may change when the system is restarted or when the file is
opened.  After a process opens a file, the identifier is constant until the
file is closed."

Well, foo.  Even if I wanted to implement this as my unique fact, the index
value won't stay constant if I close the file.

The search continues... I just wanted to make sure that I let people know
that this particular branch leads to a dead-end.

Alun.
~~~~

--
Texas Imperial Software | Try WFTPD, the Windows FTP Server. Find it
1602 Harvest Moon Place | at web site http://www.wftpd.com or email
Cedar Park TX 78613     | us at [email-masked].  VISA / MC accepted.
Fax +1 (512) 378 3246   | NT based ISPs, be sure to read details of
Phone +1 (512) 378 3246 | WFTPD Pro, NT service version - $100.
*WFTPD and WFTPD Pro now available as native Alpha versions for NT*