Windows: fix Windows 10 hibernate issue when EFI system encryption is active.

This commit is contained in:
Mounir IDRASSI 2016-08-09 23:33:22 +02:00
parent b146e235f8
commit b51d8f5386
No known key found for this signature in database
GPG Key ID: DD0C382D5FCFB8FC

View File

@ -94,7 +94,17 @@ NTSTATUS DumpFilterEntry (PFILTER_EXTENSION filterExtension, PFILTER_INITIALIZAT
// Check dump volume is located within the scope of system encryption // Check dump volume is located within the scope of system encryption
status = SendDeviceIoControlRequest (filterExtension->DeviceObject, IOCTL_DISK_GET_PARTITION_INFO, NULL, 0, &partitionInfo, sizeof (partitionInfo)); status = SendDeviceIoControlRequest (filterExtension->DeviceObject, IOCTL_DISK_GET_PARTITION_INFO, NULL, 0, &partitionInfo, sizeof (partitionInfo));
if (!NT_SUCCESS (status)) if (!NT_SUCCESS (status))
goto err; {
PARTITION_INFORMATION_EX partitionInfoEx;
status = SendDeviceIoControlRequest (filterExtension->DeviceObject, IOCTL_DISK_GET_PARTITION_INFO_EX, NULL, 0, &partitionInfoEx, sizeof (partitionInfoEx));
if (!NT_SUCCESS (status))
{
goto err;
}
// we only need starting offset
partitionInfo.StartingOffset = partitionInfoEx.StartingOffset;
}
DumpPartitionOffset = partitionInfo.StartingOffset; DumpPartitionOffset = partitionInfo.StartingOffset;