diff options
author | Todd C. Miller <millert@cvs.openbsd.org> | 1998-07-08 19:43:24 +0000 |
---|---|---|
committer | Todd C. Miller <millert@cvs.openbsd.org> | 1998-07-08 19:43:24 +0000 |
commit | d872aed5df7a08ed961ccd217e4cd47f7d7654a9 (patch) | |
tree | 2cf587586f3775c38ddd999b4f5a16e8e7928503 /usr.sbin | |
parent | 7561d9a360f21b385b317afd4abf978bbe5e4abe (diff) |
When multiplying bumber of blocks by DEV_BSIZE, cast nblocks to off_t so we don't wrap.
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/quot/quot.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.sbin/quot/quot.c b/usr.sbin/quot/quot.c index 523eed1b059..cc5857abded 100644 --- a/usr.sbin/quot/quot.c +++ b/usr.sbin/quot/quot.c @@ -1,4 +1,4 @@ -/* $OpenBSD: quot.c,v 1.4 1996/06/10 08:32:15 deraadt Exp $ */ +/* $OpenBSD: quot.c,v 1.5 1998/07/08 19:43:23 millert Exp $ */ /* $NetBSD: quot.c,v 1.7.4.1 1996/05/31 18:06:36 jtc Exp $ */ /* @@ -33,7 +33,7 @@ */ #ifndef lint -static char rcsid[] = "$Id: quot.c,v 1.4 1996/06/10 08:32:15 deraadt Exp $"; +static char rcsid[] = "$Id: quot.c,v 1.5 1998/07/08 19:43:23 millert Exp $"; #endif /* not lint */ #include <sys/param.h> @@ -70,7 +70,7 @@ static int headerlen; #ifdef COMPAT #define SIZE(n) (n) #else -#define SIZE(n) howmany((n) * DEV_BSIZE, blocksize) +#define SIZE(n) howmany(((off_t)(n)) * DEV_BSIZE, blocksize) #endif #define INOCNT(fs) ((fs)->fs_ipg) |