parted/parted-workaround-windows7-gpt-implementation.patch

19 lines
790 B
Diff

bnc#781688
---
libparted/labels/gpt.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: parted-3.1/libparted/labels/gpt.c
===================================================================
--- parted-3.1.orig/libparted/labels/gpt.c
+++ parted-3.1/libparted/labels/gpt.c
@@ -489,7 +489,7 @@ _has_hybrid_pmbr (const PedDevice *dev)
if ((mbr.PartitionRecord[0].OSType == EFI_PMBR_OSTYPE_EFI) &&
(mbr.PartitionRecord[0].StartingLBA == PED_CPU_TO_LE32(1)) &&
- (mbr.PartitionRecord[0].SizeInLBA == PED_CPU_TO_LE32(efi_gpt_expected_size)))
+ ((mbr.PartitionRecord[0].SizeInLBA == PED_CPU_TO_LE32(efi_gpt_expected_size)) || (mbr.PartitionRecord[0].SizeInLBA == PED_CPU_TO_LE32(0xFFFFFFFF))))
/* pMBR is not hybrid */
has_hybrid_pmbr = 0;