Replace UINT_MAX to UINT32_MAX.
Pointed out by: kib MFC after: 1 week
This commit is contained in:
parent
7cc6b3df80
commit
4675b2b65f
@ -262,7 +262,7 @@ g_part_mbr_create(struct g_part_table *basetable, struct g_part_parms *gpp)
|
||||
if (pp->sectorsize < MBRSIZE)
|
||||
return (ENOSPC);
|
||||
|
||||
msize = MIN(pp->mediasize / pp->sectorsize, UINT_MAX);
|
||||
msize = MIN(pp->mediasize / pp->sectorsize, UINT32_MAX);
|
||||
basetable->gpt_first = basetable->gpt_sectors;
|
||||
basetable->gpt_last = msize - (msize % basetable->gpt_sectors) - 1;
|
||||
|
||||
@ -433,7 +433,7 @@ g_part_mbr_read(struct g_part_table *basetable, struct g_consumer *cp)
|
||||
|
||||
pp = cp->provider;
|
||||
table = (struct g_part_mbr_table *)basetable;
|
||||
msize = MIN(pp->mediasize / pp->sectorsize, UINT_MAX);
|
||||
msize = MIN(pp->mediasize / pp->sectorsize, UINT32_MAX);
|
||||
|
||||
buf = g_read_data(cp, 0L, pp->sectorsize, &error);
|
||||
if (buf == NULL)
|
||||
|
@ -261,7 +261,7 @@ g_part_pc98_create(struct g_part_table *basetable, struct g_part_parms *gpp)
|
||||
|
||||
cyl = basetable->gpt_heads * basetable->gpt_sectors;
|
||||
|
||||
msize = MIN(pp->mediasize / SECSIZE, UINT_MAX);
|
||||
msize = MIN(pp->mediasize / SECSIZE, UINT32_MAX);
|
||||
basetable->gpt_first = cyl;
|
||||
basetable->gpt_last = msize - (msize % cyl) - 1;
|
||||
|
||||
@ -451,7 +451,7 @@ g_part_pc98_read(struct g_part_table *basetable, struct g_consumer *cp)
|
||||
|
||||
pp = cp->provider;
|
||||
table = (struct g_part_pc98_table *)basetable;
|
||||
msize = MIN(pp->mediasize / SECSIZE, UINT_MAX);
|
||||
msize = MIN(pp->mediasize / SECSIZE, UINT32_MAX);
|
||||
|
||||
buf = g_read_data(cp, 0L, BOOTSIZE, &error);
|
||||
if (buf == NULL)
|
||||
|
Loading…
Reference in New Issue
Block a user