mirror of
https://github.com/pbatard/rufus.git
synced 2025-05-22 02:45:11 -04:00
[core] relax the FILE_SHARE_WRITE rules during enumeration
* Should allow enumeration of drives, that other process have open with RW access, back again (looking at you, Paragon!!!)
This commit is contained in:
parent
3b4b742772
commit
23390bf911
5 changed files with 18 additions and 19 deletions
|
@ -654,8 +654,8 @@ BOOL GetDevices(DWORD devnum)
|
|||
continue;
|
||||
}
|
||||
|
||||
hDrive = CreateFileA(devint_detail_data->DevicePath, GENERIC_READ|GENERIC_WRITE, FILE_SHARE_READ,
|
||||
NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL);
|
||||
hDrive = CreateFileA(devint_detail_data->DevicePath, GENERIC_READ|GENERIC_WRITE,
|
||||
FILE_SHARE_READ|FILE_SHARE_WRITE, NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL);
|
||||
if(hDrive == INVALID_HANDLE_VALUE) {
|
||||
uprintf("Could not open '%s': %s\n", devint_detail_data->DevicePath, WindowsErrorString());
|
||||
continue;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue