diff --git a/example_test.go b/example_test.go index b45e45c3..5832349b 100644 --- a/example_test.go +++ b/example_test.go @@ -84,6 +84,7 @@ func ExampleCreate_gpt() { ProtectiveMBR: true, Partitions: []*gpt.Partition{ { + Index: 1, Start: 1 * 1024 * 1024 / 512, Size: 10 * 1024 * 1024, Type: gpt.MBRPartitionScheme, diff --git a/examples/efi_create.go b/examples/efi_create.go index cd31026f..b7a4051c 100644 --- a/examples/efi_create.go +++ b/examples/efi_create.go @@ -31,7 +31,7 @@ func CreateEfi(diskImg string) { // create a partition table table := &gpt.Table{ Partitions: []*gpt.Partition{ - {Start: uint64(partitionStart), End: uint64(partitionEnd), Type: gpt.EFISystemPartition, Name: "EFI System"}, + {Index: 1, Start: uint64(partitionStart), End: uint64(partitionEnd), Type: gpt.EFISystemPartition, Name: "EFI System"}, }, } // apply the partition table