On Wed Jul 3 17:20:22 2024 +0000, Paul Gofman wrote:
I had a brief look yesterday and there at least regardless of label and serial NtQueryVolumeInformationFile(FileFsAttributeInformation) in GetVolumeInformationByHandleW(). And NtQueryVolumeInformationFile(FileFsAttributeInformation) has fallback handling. The other thing is, I am not sure if there is any scenario when opening with GENERIC_READ will fail and without GENERIC_READ will succeed? Both should end up in Unix fd open and there is probably no way (device, or any) file can be opened without read access. Maybe that is the fallback path without GENERIC_READ should be removed instead?
Nvm the last suggestion probably, there should be the difference for Wine device file which doesn't map to Unix fd.