From 63fc86da6f7843b6545e98968a33f4eafdc0ebbf Mon Sep 17 00:00:00 2001 From: Poul-Henning Kamp Date: Mon, 20 Jan 2003 11:15:12 +0000 Subject: [PATCH] Use NEXTDOSPART instead of MAX_SLICES. --- sys/boot/i386/libi386/biosdisk.c | 5 ++--- sys/boot/pc98/libpc98/biosdisk.c | 4 ++-- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/sys/boot/i386/libi386/biosdisk.c b/sys/boot/i386/libi386/biosdisk.c index 67c0f71a824..ff41c1ad57b 100644 --- a/sys/boot/i386/libi386/biosdisk.c +++ b/sys/boot/i386/libi386/biosdisk.c @@ -39,7 +39,6 @@ #include #include -#include #include #include @@ -83,7 +82,7 @@ struct open_disk { #define BD_PARTTABOK 0x0010 struct disklabel od_disklabel; int od_nslices; /* slice count */ - struct dos_partition od_slicetab[MAX_SLICES]; + struct dos_partition od_slicetab[NEXTDOSPART]; }; /* @@ -655,7 +654,7 @@ bd_checkextended(struct open_disk *od, int slicenum) for (i = 0; i < NDOSPART; i++, dp++) { if (dp->dp_size == 0) continue; - if (od->od_nslices == MAX_SLICES) + if (od->od_nslices == NEXTDOSPART) goto done; dp->dp_start += base; bcopy(dp, &od->od_slicetab[od->od_nslices], sizeof(*dp)); diff --git a/sys/boot/pc98/libpc98/biosdisk.c b/sys/boot/pc98/libpc98/biosdisk.c index d5c0a6574ab..2d9afbd7bb9 100644 --- a/sys/boot/pc98/libpc98/biosdisk.c +++ b/sys/boot/pc98/libpc98/biosdisk.c @@ -86,7 +86,7 @@ struct open_disk { #endif struct disklabel od_disklabel; int od_nslices; /* slice count */ - struct pc98_partition od_slicetab[MAX_SLICES]; + struct pc98_partition od_slicetab[NEXTDOSPART]; }; /* @@ -778,7 +778,7 @@ bd_checkextended(struct open_disk *od, int slicenum) for (i = 0; i < NDOSPART; i++, dp++) { if (dp->dp_size == 0) continue; - if (od->od_nslices == MAX_SLICES) + if (od->od_nslices == NEXTDOSPART) goto done; dp->dp_start += base; bcopy(dp, &od->od_slicetab[od->od_nslices], sizeof(*dp));