summaryrefslogtreecommitdiffstats
path: root/usr.sbin/quot
diff options
context:
space:
mode:
authortjr <tjr@FreeBSD.org>2003-04-25 10:07:50 +0000
committertjr <tjr@FreeBSD.org>2003-04-25 10:07:50 +0000
commit5794ae48635b717529a6b66028bedddf92895670 (patch)
tree1b24f1c851dd8a67a23ab6946608d616e2ae02fd /usr.sbin/quot
parent4985f242d1195df30e226b467766c7a9c9003231 (diff)
downloadFreeBSD-src-5794ae48635b717529a6b66028bedddf92895670.zip
FreeBSD-src-5794ae48635b717529a6b66028bedddf92895670.tar.gz
Repair the UFS2 superblock location consistency check so that it succeeds
on valid superblocks instead of issuing the error "not a BSD filesystem". fs_sblockloc is a byte offset, not a fragment number. This change makes quot work properly on UFS2 filesystems, which is important now that UFS2 is the default.
Diffstat (limited to 'usr.sbin/quot')
-rw-r--r--usr.sbin/quot/quot.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.sbin/quot/quot.c b/usr.sbin/quot/quot.c
index 4214844..bd1075d 100644
--- a/usr.sbin/quot/quot.c
+++ b/usr.sbin/quot/quot.c
@@ -563,7 +563,7 @@ quot(name,mp)
fs = (struct fs *)superblock;
if ((fs->fs_magic == FS_UFS1_MAGIC ||
(fs->fs_magic == FS_UFS2_MAGIC &&
- fs->fs_sblockloc == numfrags(fs, sblock_try[i]))) &&
+ fs->fs_sblockloc == sblock_try[i])) &&
fs->fs_bsize <= MAXBSIZE &&
fs->fs_bsize >= sizeof(struct fs))
break;
OpenPOWER on IntegriCloud