aboutsummaryrefslogtreecommitdiffstats
path: root/block/partitions
diff options
context:
space:
mode:
Diffstat (limited to 'block/partitions')
-rw-r--r--block/partitions/mac.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/block/partitions/mac.c b/block/partitions/mac.c
index 11f688bd76c5..76d8ba6379a9 100644
--- a/block/partitions/mac.c
+++ b/block/partitions/mac.c
@@ -63,6 +63,10 @@ int mac_partition(struct parsed_partitions *state)
63 put_dev_sector(sect); 63 put_dev_sector(sect);
64 return 0; 64 return 0;
65 } 65 }
66
67 if (blocks_in_map >= state->limit)
68 blocks_in_map = state->limit - 1;
69
66 strlcat(state->pp_buf, " [mac]", PAGE_SIZE); 70 strlcat(state->pp_buf, " [mac]", PAGE_SIZE);
67 for (slot = 1; slot <= blocks_in_map; ++slot) { 71 for (slot = 1; slot <= blocks_in_map; ++slot) {
68 int pos = slot * secsize; 72 int pos = slot * secsize;