summaryrefslogtreecommitdiff
path: root/sys/arch/arm/arm/disksubr.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/arch/arm/arm/disksubr.c')
-rw-r--r--sys/arch/arm/arm/disksubr.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/sys/arch/arm/arm/disksubr.c b/sys/arch/arm/arm/disksubr.c
index 203528f064c..818d8e695c5 100644
--- a/sys/arch/arm/arm/disksubr.c
+++ b/sys/arch/arm/arm/disksubr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: disksubr.c,v 1.26 2007/02/18 13:49:22 krw Exp $ */
+/* $OpenBSD: disksubr.c,v 1.27 2007/05/29 05:08:19 krw Exp $ */
/* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */
/*
@@ -83,8 +83,10 @@ readdisklabel(dev, strat, lp, osdep, spoofonly)
lp->d_secsize = DEV_BSIZE;
if (lp->d_secperunit == 0)
lp->d_secperunit = 0x1fffffff;
- if (lp->d_secpercyl == 0)
- return ("invalid geometry");
+ if (lp->d_secpercyl == 0) {
+ msg = "invalid geometry";
+ goto done;
+ }
lp->d_npartitions = RAW_PART + 1;
for (i = 0; i < RAW_PART; i++) {
lp->d_partitions[i].p_size = 0;