Ignore:
Timestamp:
2/12/2010 12:56:35 PM (2 years ago)
Author:
lowjoel
Message:

Instead of hardcoding 0x80 to be passed to CreateFile?, use the named constant FILE_READ_ATTRIBUTES. Also, use this flag when querying NTFS volume information so that non-administrators can query NTFS volume information (e.g. MFT record size)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/eraser6/Eraser.Util/VolumeInfo.cs

    r1838 r1841  
    679679            get 
    680680            { 
    681                 using (SafeFileHandle handle = OpenHandle(0x80u, FileShare.ReadWrite, 
    682                     FileOptions.None)) 
     681                using (SafeFileHandle handle = OpenHandle(NativeMethods.FILE_READ_ATTRIBUTES, 
     682                    FileShare.ReadWrite, FileOptions.None)) 
    683683                { 
    684684                    //This only works if the user has turned on the disk performance 
Note: See TracChangeset for help on using the changeset viewer.