Our current storage stack iteration considers that any CDROM is read-only and forces it.
Reflect that fact in UDFS; we cannot assume that our device won't be readonly.

CORE-4375

svn path=/trunk/; revision=74781
This commit is contained in:
Pierre Schweitzer 2017-06-03 18:29:44 +00:00
parent bcd5f02d0f
commit 53c317d86d

View file

@ -462,8 +462,15 @@ UDFQueryFsDeviceInfo(
KdPrint((" UDFQueryFsDeviceInfo: \n")); KdPrint((" UDFQueryFsDeviceInfo: \n"));
// Update the output buffer. // Update the output buffer.
if (Vcb->TargetDeviceObject->DeviceType != FILE_DEVICE_CD_ROM && Vcb->TargetDeviceObject->DeviceType != FILE_DEVICE_DVD)
{
ASSERT(! (Vcb->TargetDeviceObject->Characteristics & (FILE_READ_ONLY_DEVICE | FILE_WRITE_ONCE_MEDIA))); ASSERT(! (Vcb->TargetDeviceObject->Characteristics & (FILE_READ_ONLY_DEVICE | FILE_WRITE_ONCE_MEDIA)));
Buffer->Characteristics = Vcb->TargetDeviceObject->Characteristics & ~(FILE_READ_ONLY_DEVICE | FILE_WRITE_ONCE_MEDIA); Buffer->Characteristics = Vcb->TargetDeviceObject->Characteristics & ~(FILE_READ_ONLY_DEVICE | FILE_WRITE_ONCE_MEDIA);
}
else
{
Buffer->Characteristics = Vcb->TargetDeviceObject->Characteristics;
}
Buffer->DeviceType = Vcb->TargetDeviceObject->DeviceType; Buffer->DeviceType = Vcb->TargetDeviceObject->DeviceType;
KdPrint((" Characteristics %x, DeviceType %x\n", Buffer->Characteristics, Buffer->DeviceType)); KdPrint((" Characteristics %x, DeviceType %x\n", Buffer->Characteristics, Buffer->DeviceType));
// Adjust the length variable // Adjust the length variable