UInt32x32To64(GET_PARTITION_LENGTH(PartitionDescriptor),
SectorSize);
- /* FIXME: REACTOS HACK */
+ // BUGBUGBUG: The correct partition numbers seem to cause boot failures!!!
+// PartitionInfo->PartitionNumber = (!IsContainerPartition(PartitionType)) ? i : 0;
PartitionInfo->PartitionNumber = i + 1;
}
else
PartitionInfo->PartitionLength.QuadPart = 0;
PartitionInfo->HiddenSectors = 0;
- /* FIXME: REACTOS HACK */
PartitionInfo->PartitionNumber = 0;
}
}
/* Free the buffer and check for success */
if (Buffer) ExFreePoolWithTag(Buffer, TAG_FILE_SYSTEM);
- if (!NT_SUCCESS(Status)) ExFreePoolWithTag(*PartitionBuffer, TAG_FILE_SYSTEM);
+ if (!NT_SUCCESS(Status))
+ {
+ ExFreePoolWithTag(*PartitionBuffer, TAG_FILE_SYSTEM);
+ *PartitionBuffer = NULL;
+ }
/* Return status */
return Status;