diff options
Diffstat (limited to 'parted/parted.c')
-rw-r--r-- | parted/parted.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/parted/parted.c b/parted/parted.c index 96da30d..36c39c7 100644 --- a/parted/parted.c +++ b/parted/parted.c @@ -1215,9 +1215,8 @@ _print_disk_info (const PedDevice *dev, const PedDisk *diskp) ul_jsonwrt_value_u64 (&json, "physical-sector-size", dev->phys_sector_size); ul_jsonwrt_value_s (&json, "label", pt_name); if (diskp) { - if (diskp->type->ops->get_max_primary_partition_count) - ul_jsonwrt_value_u64 (&json, "max-partitions", - diskp->type->ops->get_max_primary_partition_count(diskp)); + ul_jsonwrt_value_u64 (&json, "max-partitions", + ped_disk_get_max_primary_partition_count(diskp)); disk_print_flags_json (diskp); } } else { |