Changeset 1872 for trunk/eraser6/Eraser.Manager/Task.cs
- Timestamp:
- 3/1/2010 9:36:02 AM (2 years ago)
- File:
-
- 1 edited
-
trunk/eraser6/Eraser.Manager/Task.cs (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/eraser6/Eraser.Manager/Task.cs
r1853 r1872 461 461 { 462 462 } 463 catch (IOException) 464 { 465 if (System.Runtime.InteropServices.Marshal.GetLastWin32Error() == 466 Win32ErrorCode.SharingViolation) 467 { 468 //The system cannot open the file, try to force the file handle to close. 469 if (!ManagerLibrary.Settings.ForceUnlockLockedFiles) 470 throw; 471 472 foreach (OpenHandle handle in OpenHandle.Items) 473 if (handle.Path == file && handle.Close()) 474 { 475 GetPathADSes(list, out totalSize, file); 476 return; 477 } 478 } 479 else 463 catch (SharingViolationException) 464 { 465 //The system cannot open the file, try to force the file handle to close. 466 if (!ManagerLibrary.Settings.ForceUnlockLockedFiles) 480 467 throw; 468 469 foreach (OpenHandle handle in OpenHandle.Items) 470 if (handle.Path == file && handle.Close()) 471 { 472 GetPathADSes(list, out totalSize, file); 473 return; 474 } 481 475 } 482 476 catch (UnauthorizedAccessException e)
Note: See TracChangeset
for help on using the changeset viewer.
