diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2007-06-14 03:29:35 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2007-06-14 03:29:35 +0000 |
commit | 4c6abb7bc0e382a4196ec4b0e38dff800b1631df (patch) | |
tree | 13d4701745f7fcc5b3095d51ecb98d41c8f9c656 /sys/arch/luna88k | |
parent | 096f1fa7d8139f8469e269112fb4efa6602528bd (diff) |
do not depend on previous loop variable, use a constant instead
Diffstat (limited to 'sys/arch/luna88k')
-rw-r--r-- | sys/arch/luna88k/luna88k/disksubr.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/arch/luna88k/luna88k/disksubr.c b/sys/arch/luna88k/luna88k/disksubr.c index 41c35069ea1..4a4c529268e 100644 --- a/sys/arch/luna88k/luna88k/disksubr.c +++ b/sys/arch/luna88k/luna88k/disksubr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: disksubr.c,v 1.25 2007/06/12 20:57:42 deraadt Exp $ */ +/* $OpenBSD: disksubr.c,v 1.26 2007/06/14 03:29:34 deraadt Exp $ */ /* $NetBSD: disksubr.c,v 1.12 2002/02/19 17:09:44 wiz Exp $ */ /* @@ -135,9 +135,9 @@ readdisklabel(dev_t dev, void (*strat)(struct buf *), DL_SETPSIZE(&lp->d_partitions[i], 0); DL_SETPOFFSET(&lp->d_partitions[i], 0); } - if (DL_GETPSIZE(&lp->d_partitions[i]) == 0) - DL_SETPSIZE(&lp->d_partitions[i], DL_GETDSIZE(lp)); - DL_SETPOFFSET(&lp->d_partitions[i], 0); + if (DL_GETPSIZE(&lp->d_partitions[RAW_PART]) == 0) + DL_SETPSIZE(&lp->d_partitions[RAW_PART], DL_GETDSIZE(lp)); + DL_SETPOFFSET(&lp->d_partitions[RAW_PART], 0); /* don't read the on-disk label if we are in spoofed-only mode */ if (spoofonly) |