From df43751da9dc2ab7ac34da77ddd1fa9ba58a284b Mon Sep 17 00:00:00 2001 From: Theo de Raadt Date: Fri, 9 Oct 2009 04:25:35 +0000 Subject: initialize the disk size instead of getting a random value (always 0) off the stack. this lets disklabels work on non-sgivol disks. ok miod --- sys/arch/sgi/sgi/disksubr.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'sys/arch/sgi') diff --git a/sys/arch/sgi/sgi/disksubr.c b/sys/arch/sgi/sgi/disksubr.c index d0571d2176b..8d98bca0506 100644 --- a/sys/arch/sgi/sgi/disksubr.c +++ b/sys/arch/sgi/sgi/disksubr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: disksubr.c,v 1.17 2009/08/13 15:23:11 deraadt Exp $ */ +/* $OpenBSD: disksubr.c,v 1.18 2009/10/09 04:25:34 deraadt Exp $ */ /* * Copyright (c) 1999 Michael Shalayeff @@ -113,8 +113,8 @@ readsgilabel(struct buf *bp, void (*strat)(struct buf *), { struct sgilabel *dlp; int i, *p, cs = 0; - int fsoffs = 0; - u_int fsend; + u_int64_t fsoffs = 0; + u_int64_t fsend = DL_GETBEND(lp); int offset; bp->b_blkno = 0; -- cgit v1.2.3