diff options
author | peter <peter@FreeBSD.org> | 1997-03-11 12:20:21 +0000 |
---|---|---|
committer | peter <peter@FreeBSD.org> | 1997-03-11 12:20:21 +0000 |
commit | ac28da2dc002612b2fd129500af8084d63aa8504 (patch) | |
tree | 8cadfc9709953ec63a6c3fe257fe499055b9f832 /sbin/fsck_ifs/pass4.c | |
parent | 683ee3c015f8c8071f4de0e2cd952c8643315c98 (diff) | |
download | FreeBSD-src-ac28da2dc002612b2fd129500af8084d63aa8504.zip FreeBSD-src-ac28da2dc002612b2fd129500af8084d63aa8504.tar.gz |
Merge from Lite2. Note that Lite2 has it's own filesystem clean check
skipping code that overrides ours sooner. One should be eliminated,
but for now it works.
Diffstat (limited to 'sbin/fsck_ifs/pass4.c')
-rw-r--r-- | sbin/fsck_ifs/pass4.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/sbin/fsck_ifs/pass4.c b/sbin/fsck_ifs/pass4.c index df8f722..e20f6fa 100644 --- a/sbin/fsck_ifs/pass4.c +++ b/sbin/fsck_ifs/pass4.c @@ -32,18 +32,19 @@ */ #ifndef lint -static const char sccsid[] = "@(#)pass4.c 8.1 (Berkeley) 6/5/93"; +static const char sccsid[] = "@(#)pass4.c 8.4 (Berkeley) 4/28/95"; #endif /* not lint */ #include <sys/param.h> #include <sys/time.h> + #include <ufs/ufs/dinode.h> #include <ufs/ffs/fs.h> -#include <stdlib.h> + +#include <err.h> #include <string.h> -#include "fsck.h" -int pass4check(); +#include "fsck.h" void pass4() @@ -54,7 +55,7 @@ pass4() struct inodesc idesc; int n; - bzero((char *)&idesc, sizeof(struct inodesc)); + memset(&idesc, 0, sizeof(struct inodesc)); idesc.id_type = ADDR; idesc.id_func = pass4check; for (inumber = ROOTINO; inumber <= lastino; inumber++) { @@ -98,7 +99,7 @@ pass4() break; default: - errexit("BAD STATE %d FOR INODE I=%d", + errx(EEXIT, "BAD STATE %d FOR INODE I=%d", statemap[inumber], inumber); } } @@ -110,7 +111,7 @@ pass4check(idesc) { register struct dups *dlp; int nfrags, res = KEEPON; - daddr_t blkno = idesc->id_blkno; + ufs_daddr_t blkno = idesc->id_blkno; for (nfrags = idesc->id_numfrags; nfrags > 0; blkno++, nfrags--) { if (chkrange(blkno, 1)) { |