title: How to find if an NTFS logical cluster is free?
body: <p>I would like to write a program that reads all the unused clusters on an NTFS volumne.  (I'm looking to recover data from a file that was accidentally truncated).  </p>
  
  <p>According to <a href="https://stackoverflow.com/questions/2350181/how-to-read-individual-sectors-clusters-using-deviceiocontrol-in-windows">this page</a> I can call SetFilePointer() and ReadFile() on the volume handle to go through each logical cluster on the volume.  But how do I know which clusters are being used by files, and which are free?</p>