--- trunk/reactos/ntoskrnl/io/disk.c 2005-08-23 17:42:12 UTC (rev 17484)
+++ trunk/reactos/ntoskrnl/io/disk.c 2005-08-23 17:43:58 UTC (rev 17485)
@@ -907,7 +907,8 @@
if ((ReturnRecognizedPartitions == FALSE) ||
((ReturnRecognizedPartitions == TRUE) &&
- IsRecognizedPartition(PartitionSector->Partition[i].PartitionType)))
+ !IsContainerPartition(PartitionSector->Partition[i].PartitionType) &&
+ PartitionSector->Partition[i].PartitionType != PARTITION_ENTRY_UNUSED))
{
/* handle normal partition */
DPRINT("Partition %u: Normal Partition\n", i);
@@ -936,13 +937,17 @@
LayoutBuffer->PartitionEntry[Count].HiddenSectors =
PartitionSector->Partition[i].StartingBlock;
- if (IsRecognizedPartition(PartitionSector->Partition[i].PartitionType))
+ if (!IsContainerPartition(PartitionSector->Partition[i].PartitionType) &&
+ PartitionSector->Partition[i].PartitionType != PARTITION_ENTRY_UNUSED)
{
+ LayoutBuffer->PartitionEntry[Count].RecognizedPartition = TRUE;
+ /* WinXP returns garbage as PartitionNumber */
LayoutBuffer->PartitionEntry[Count].PartitionNumber = Number;
Number++;
}
else
{
+ LayoutBuffer->PartitionEntry[Count].RecognizedPartition = FALSE;
LayoutBuffer->PartitionEntry[Count].PartitionNumber = 0;
}
@@ -950,8 +955,6 @@
PartitionSector->Partition[i].PartitionType;
LayoutBuffer->PartitionEntry[Count].BootIndicator =
(PartitionSector->Partition[i].BootFlags & 0x80)?TRUE:FALSE;
- LayoutBuffer->PartitionEntry[Count].RecognizedPartition =
- IsRecognizedPartition (PartitionSector->Partition[i].PartitionType);
LayoutBuffer->PartitionEntry[Count].RewritePartition = FALSE;
DPRINT(" %ld: nr: %d boot: %1x type: %x start: 0x%I64x count: 0x%I64x rec: %d\n",