Changeset 1837
- Timestamp:
- 2/12/2010 12:50:13 PM (3 years ago)
- File:
-
- 1 edited
-
trunk/eraser6/Eraser.Util/VolumeInfo.cs (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/eraser6/Eraser.Util/VolumeInfo.cs
r1802 r1837 643 643 } 644 644 645 return OpenHandle(iAccess, share, options); 646 } 647 648 private SafeFileHandle OpenHandle(uint access, FileShare share, FileOptions options) 649 { 645 650 //Sharing mode 646 651 if ((share & FileShare.Inheritable) != 0) … … 655 660 if (openPath.Length > 0 && openPath[openPath.Length - 1] == '\\') 656 661 openPath = openPath.Remove(openPath.Length - 1); 657 SafeFileHandle result = NativeMethods.CreateFile(openPath, iAccess,662 SafeFileHandle result = NativeMethods.CreateFile(openPath, access, 658 663 (uint)share, IntPtr.Zero, (uint)FileMode.Open, (uint)options, IntPtr.Zero); 659 664 if (result.IsInvalid) … … 674 679 get 675 680 { 676 using (SafeFileHandle handle = OpenHandle( FileAccess.Read,681 using (SafeFileHandle handle = OpenHandle(0x80u, 677 682 FileShare.ReadWrite, FileOptions.None)) 678 683 {
Note: See TracChangeset
for help on using the changeset viewer.
