Module Name:    src
Committed By:   riastradh
Date:           Tue Jul  4 20:40:53 UTC 2023

Modified Files:
        src/sbin/fsck_ffs: dir.c extern.h fsck.h inode.c main.c pass1.c pass2.c
            pass4.c pass5.c pass6.c quota2.c setup.c utilities.c

Log Message:
fsck_ffs(8): Fix whitespace issues.

- Nix trailing whitespace.
- Omit excessive blank lines.
- Insert missing blank lines between $NetBSD$ and copyright.

No functional change intended.


To generate a diff of this commit:
cvs rdiff -u -r1.61 -r1.62 src/sbin/fsck_ffs/dir.c
cvs rdiff -u -r1.28 -r1.29 src/sbin/fsck_ffs/extern.h
cvs rdiff -u -r1.57 -r1.58 src/sbin/fsck_ffs/fsck.h src/sbin/fsck_ffs/pass5.c
cvs rdiff -u -r1.76 -r1.77 src/sbin/fsck_ffs/inode.c
cvs rdiff -u -r1.91 -r1.92 src/sbin/fsck_ffs/main.c
cvs rdiff -u -r1.63 -r1.64 src/sbin/fsck_ffs/pass1.c
cvs rdiff -u -r1.52 -r1.53 src/sbin/fsck_ffs/pass2.c
cvs rdiff -u -r1.30 -r1.31 src/sbin/fsck_ffs/pass4.c
cvs rdiff -u -r1.4 -r1.5 src/sbin/fsck_ffs/pass6.c
cvs rdiff -u -r1.7 -r1.8 src/sbin/fsck_ffs/quota2.c
cvs rdiff -u -r1.107 -r1.108 src/sbin/fsck_ffs/setup.c
cvs rdiff -u -r1.69 -r1.70 src/sbin/fsck_ffs/utilities.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sbin/fsck_ffs/dir.c
diff -u src/sbin/fsck_ffs/dir.c:1.61 src/sbin/fsck_ffs/dir.c:1.62
--- src/sbin/fsck_ffs/dir.c:1.61	Sun May  5 14:59:06 2019
+++ src/sbin/fsck_ffs/dir.c	Tue Jul  4 20:40:53 2023
@@ -1,4 +1,4 @@
-/*	$NetBSD: dir.c,v 1.61 2019/05/05 14:59:06 christos Exp $	*/
+/*	$NetBSD: dir.c,v 1.62 2023/07/04 20:40:53 riastradh Exp $	*/
 
 /*
  * Copyright (c) 1980, 1986, 1993
@@ -34,7 +34,7 @@
 #if 0
 static char sccsid[] = "@(#)dir.c	8.8 (Berkeley) 4/28/95";
 #else
-__RCSID("$NetBSD: dir.c,v 1.61 2019/05/05 14:59:06 christos Exp $");
+__RCSID("$NetBSD: dir.c,v 1.62 2023/07/04 20:40:53 riastradh Exp $");
 #endif
 #endif /* not lint */
 
@@ -230,7 +230,7 @@ dirscan(struct inodesc *idesc)
 			dirty(bp);
 			sbdirty();
 		}
-		if (n & STOP) 
+		if (n & STOP)
 			return (n);
 	}
 	return (idesc->id_filesize > 0 ? KEEPON : STOP);
@@ -265,7 +265,7 @@ fsck_readdir(struct inodesc *idesc)
 		dp->d_name[0] = '\0';
 		if (fix)
 			dirty(bp);
-		else 
+		else
 			markclean = 0;
 		idesc->id_loc += dirblksiz;
 		idesc->id_filesize -= dirblksiz;
@@ -294,7 +294,7 @@ dpok:
 		dp->d_reclen = iswap16(iswap16(dp->d_reclen) + size);
 		if (fix)
 			dirty(bp);
-		else 
+		else
 			markclean = 0;
 	}
 	return (dp);
@@ -308,7 +308,7 @@ dpok:
  *	0: bad
  */
 static int
-dircheck(struct inodesc *idesc, struct direct *dp, struct bufarea *bp) 
+dircheck(struct inodesc *idesc, struct direct *dp, struct bufarea *bp)
 {
 	uint8_t namlen, type;
 	uint16_t reclen;
@@ -497,7 +497,7 @@ adjust(struct inodesc *idesc, int lcnt)
 		if (preen || reply("ADJUST") == 1) {
 			DIP_SET(dp, nlink, iswap16(nlink - lcnt));
 			inodirty();
-		} else 
+		} else
 			markclean = 0;
 	}
 }
@@ -715,7 +715,7 @@ makeentry(ino_t parent, ino_t ino, const
 	union dinode *dp;
 	struct inodesc idesc;
 	char pathbuf[MAXPATHLEN + 1];
-	
+
 	if (parent < UFS_ROOTINO || parent >= maxino ||
 	    ino < UFS_ROOTINO || ino >= maxino)
 		return (0);

Index: src/sbin/fsck_ffs/extern.h
diff -u src/sbin/fsck_ffs/extern.h:1.28 src/sbin/fsck_ffs/extern.h:1.29
--- src/sbin/fsck_ffs/extern.h:1.28	Thu Nov 17 06:40:38 2022
+++ src/sbin/fsck_ffs/extern.h	Tue Jul  4 20:40:53 2023
@@ -1,4 +1,4 @@
-/*	$NetBSD: extern.h,v 1.28 2022/11/17 06:40:38 chs Exp $	*/
+/*	$NetBSD: extern.h,v 1.29 2023/07/04 20:40:53 riastradh Exp $	*/
 
 /*
  * Copyright (c) 1994 James A. Jegers
@@ -88,7 +88,6 @@ void		remove_uquot(struct uquot_hash *,s
 void		update_uquot(ino_t, uid_t, gid_t, int64_t, int64_t);
 int		is_quota_inode(ino_t);
 
-
 int		check_wapbl(void);
 void		replay_wapbl(void);
 void		cleanup_wapbl(void);

Index: src/sbin/fsck_ffs/fsck.h
diff -u src/sbin/fsck_ffs/fsck.h:1.57 src/sbin/fsck_ffs/fsck.h:1.58
--- src/sbin/fsck_ffs/fsck.h:1.57	Sat Jan 14 12:12:50 2023
+++ src/sbin/fsck_ffs/fsck.h	Tue Jul  4 20:40:53 2023
@@ -1,4 +1,4 @@
-/*	$NetBSD: fsck.h,v 1.57 2023/01/14 12:12:50 christos Exp $	*/
+/*	$NetBSD: fsck.h,v 1.58 2023/07/04 20:40:53 riastradh Exp $	*/
 
 /*
  * Copyright (c) 1980, 1986, 1993
@@ -101,7 +101,6 @@ extern struct inostatlist {
 	struct inostat *il_stat;/* inostat info for this cylinder group */
 } *inostathead;
 
-
 /*
  * buffer cache structure.
  */
@@ -205,14 +204,14 @@ struct inodesc {
 
 /*
  * Linked list of duplicate blocks.
- * 
+ *
  * The list is composed of two parts. The first part of the
  * list (from duplist through the node pointed to by muldup)
- * contains a single copy of each duplicate block that has been 
+ * contains a single copy of each duplicate block that has been
  * found. The second part of the list (from muldup to the end)
  * contains duplicate blocks that have been found more than once.
  * To check if a block has been found as a duplicate it is only
- * necessary to search from duplist through muldup. To find the 
+ * necessary to search from duplist through muldup. To find the
  * total number of times that a block has been found as a duplicate
  * the entire list must be searched for occurrences of the block
  * in question. The following diagram shows a sample list where
Index: src/sbin/fsck_ffs/pass5.c
diff -u src/sbin/fsck_ffs/pass5.c:1.57 src/sbin/fsck_ffs/pass5.c:1.58
--- src/sbin/fsck_ffs/pass5.c:1.57	Sun Jan  8 05:25:24 2023
+++ src/sbin/fsck_ffs/pass5.c	Tue Jul  4 20:40:53 2023
@@ -1,4 +1,4 @@
-/*	$NetBSD: pass5.c,v 1.57 2023/01/08 05:25:24 chs Exp $	*/
+/*	$NetBSD: pass5.c,v 1.58 2023/07/04 20:40:53 riastradh Exp $	*/
 
 /*
  * Copyright (c) 1980, 1986, 1993
@@ -34,7 +34,7 @@
 #if 0
 static char sccsid[] = "@(#)pass5.c	8.9 (Berkeley) 4/28/95";
 #else
-__RCSID("$NetBSD: pass5.c,v 1.57 2023/01/08 05:25:24 chs Exp $");
+__RCSID("$NetBSD: pass5.c,v 1.58 2023/07/04 20:40:53 riastradh Exp $");
 #endif
 #endif /* not lint */
 
@@ -507,7 +507,7 @@ pass5(void)
 #endif /* PROGRESS */
 }
 
-void 
+void
 print_bmap(u_char *map, uint32_t size)
 {
 	uint32_t i, j;

Index: src/sbin/fsck_ffs/inode.c
diff -u src/sbin/fsck_ffs/inode.c:1.76 src/sbin/fsck_ffs/inode.c:1.77
--- src/sbin/fsck_ffs/inode.c:1.76	Tue Jul  4 20:40:22 2023
+++ src/sbin/fsck_ffs/inode.c	Tue Jul  4 20:40:53 2023
@@ -1,4 +1,4 @@
-/*	$NetBSD: inode.c,v 1.76 2023/07/04 20:40:22 riastradh Exp $	*/
+/*	$NetBSD: inode.c,v 1.77 2023/07/04 20:40:53 riastradh Exp $	*/
 
 /*
  * Copyright (c) 1980, 1986, 1993
@@ -34,7 +34,7 @@
 #if 0
 static char sccsid[] = "@(#)inode.c	8.8 (Berkeley) 4/28/95";
 #else
-__RCSID("$NetBSD: inode.c,v 1.76 2023/07/04 20:40:22 riastradh Exp $");
+__RCSID("$NetBSD: inode.c,v 1.77 2023/07/04 20:40:53 riastradh Exp $");
 #endif
 #endif /* not lint */
 
@@ -251,7 +251,7 @@ iblock(struct inodesc *idesc, long ileve
 				    pathbuf);
 				if (reply("ADJUST LENGTH") == 1) {
 					dp = ginode(idesc->id_number);
-					DIP_SET(dp, size, 
+					DIP_SET(dp, size,
 					    iswap64(iswap64(DIP(dp, size))
 						- isize));
 					isize = 0;
@@ -565,11 +565,11 @@ inocleanup(void)
 	free((char *)inpsort);
 	inphead = inpsort = NULL;
 }
-	
+
 void
 inodirty(void)
 {
-	
+
 	dirty(pbp);
 }
 
@@ -910,7 +910,7 @@ readblk(union dinode *dp, off_t offset, 
 		else
 			blkno -= nblks;
 	}
-	if (ilevel > UFS_NIADDR) 
+	if (ilevel > UFS_NIADDR)
 		errexit("bad ofsset %" PRIu64 " to readblk", offset);
 
 	/* get the first indirect block */
@@ -990,7 +990,7 @@ expandfile(union dinode *dp)
 		else
 			blkno -= nblks;
 	}
-	if (ilevel > UFS_NIADDR) 
+	if (ilevel > UFS_NIADDR)
 		errexit("bad filesize %" PRIu64 " to expandfile", filesize);
 
 	/* get the first indirect block, allocating if needed */
@@ -1038,7 +1038,7 @@ expandfile(union dinode *dp)
 		errexit("INTERNAL ERROR: "
 		    "expandfile() failed to allocate a new block\n");
 	}
-	
+
 out:
 	filesize += sblock->fs_bsize;
 	if (is_ufs2) {

Index: src/sbin/fsck_ffs/main.c
diff -u src/sbin/fsck_ffs/main.c:1.91 src/sbin/fsck_ffs/main.c:1.92
--- src/sbin/fsck_ffs/main.c:1.91	Sat Jan  7 19:41:29 2023
+++ src/sbin/fsck_ffs/main.c	Tue Jul  4 20:40:53 2023
@@ -1,4 +1,4 @@
-/*	$NetBSD: main.c,v 1.91 2023/01/07 19:41:29 chs Exp $	*/
+/*	$NetBSD: main.c,v 1.92 2023/07/04 20:40:53 riastradh Exp $	*/
 
 /*
  * Copyright (c) 1980, 1986, 1993
@@ -39,7 +39,7 @@ __COPYRIGHT("@(#) Copyright (c) 1980, 19
 #if 0
 static char sccsid[] = "@(#)main.c	8.6 (Berkeley) 5/14/95";
 #else
-__RCSID("$NetBSD: main.c,v 1.91 2023/01/07 19:41:29 chs Exp $");
+__RCSID("$NetBSD: main.c,v 1.92 2023/07/04 20:40:53 riastradh Exp $");
 #endif
 #endif /* not lint */
 
@@ -284,7 +284,6 @@ main(int argc, char *argv[])
 			snap_internal = 0;
 		}
 	}
-			
 
 	argc -= optind;
 	argv += optind;
@@ -318,7 +317,7 @@ main(int argc, char *argv[])
 
 		if (path == NULL)
 			pfatal("Can't check %s\n", *argv);
-		
+
 		if (snap_backup || snap_internal) {
 			char *snap_dev;
 			int snapfd;

Index: src/sbin/fsck_ffs/pass1.c
diff -u src/sbin/fsck_ffs/pass1.c:1.63 src/sbin/fsck_ffs/pass1.c:1.64
--- src/sbin/fsck_ffs/pass1.c:1.63	Sat Jan  7 19:41:29 2023
+++ src/sbin/fsck_ffs/pass1.c	Tue Jul  4 20:40:53 2023
@@ -1,4 +1,4 @@
-/*	$NetBSD: pass1.c,v 1.63 2023/01/07 19:41:29 chs Exp $	*/
+/*	$NetBSD: pass1.c,v 1.64 2023/07/04 20:40:53 riastradh Exp $	*/
 
 /*
  * Copyright (c) 1980, 1986, 1993
@@ -34,7 +34,7 @@
 #if 0
 static char sccsid[] = "@(#)pass1.c	8.6 (Berkeley) 4/28/95";
 #else
-__RCSID("$NetBSD: pass1.c,v 1.63 2023/01/07 19:41:29 chs Exp $");
+__RCSID("$NetBSD: pass1.c,v 1.64 2023/07/04 20:40:53 riastradh Exp $");
 #endif
 #endif /* not lint */
 
@@ -243,13 +243,13 @@ checkinode(ino_t inumber, struct inodesc
 	mode = iswap16(DIP(dp, mode)) & IFMT;
 	size = iswap64(DIP(dp, size));
 	if (mode == 0) {
-		if ((is_ufs2 && 
+		if ((is_ufs2 &&
 		    (memcmp(dp->dp2.di_db, ufs2_zino.di_db,
 			UFS_NDADDR * sizeof(int64_t)) ||
 		    memcmp(dp->dp2.di_ib, ufs2_zino.di_ib,
 			UFS_NIADDR * sizeof(int64_t))))
 		    ||
-		    (!is_ufs2 && 
+		    (!is_ufs2 &&
 		    (memcmp(dp->dp1.di_db, ufs1_zino.di_db,
 			UFS_NDADDR * sizeof(int32_t)) ||
 		    memcmp(dp->dp1.di_ib, ufs1_zino.di_ib,
@@ -333,7 +333,7 @@ checkinode(ino_t inumber, struct inodesc
 		    (sblock->fs_maxsymlinklen == 0 && DIP(dp, blocks) == 0)) {
 			if (is_ufs2)
 				ndb = howmany(size, sizeof(int64_t));
-			else	
+			else
 				ndb = howmany(size, sizeof(int32_t));
 			if (ndb > UFS_NDADDR) {
 				j = ndb - UFS_NDADDR;

Index: src/sbin/fsck_ffs/pass2.c
diff -u src/sbin/fsck_ffs/pass2.c:1.52 src/sbin/fsck_ffs/pass2.c:1.53
--- src/sbin/fsck_ffs/pass2.c:1.52	Mon Mar 27 22:53:37 2023
+++ src/sbin/fsck_ffs/pass2.c	Tue Jul  4 20:40:53 2023
@@ -1,4 +1,4 @@
-/*	$NetBSD: pass2.c,v 1.52 2023/03/27 22:53:37 chs Exp $	*/
+/*	$NetBSD: pass2.c,v 1.53 2023/07/04 20:40:53 riastradh Exp $	*/
 
 /*
  * Copyright (c) 1980, 1986, 1993
@@ -34,7 +34,7 @@
 #if 0
 static char sccsid[] = "@(#)pass2.c	8.9 (Berkeley) 4/28/95";
 #else
-__RCSID("$NetBSD: pass2.c,v 1.52 2023/03/27 22:53:37 chs Exp $");
+__RCSID("$NetBSD: pass2.c,v 1.53 2023/07/04 20:40:53 riastradh Exp $");
 #endif
 #endif /* not lint */
 
@@ -150,7 +150,7 @@ pass2(void)
 		if (got_siginfo) {
 			fprintf(stderr,
 			    "%s: phase 2: dir %ld of %d (%d%%)\n", cdevname(),
-			    (long)(inpp - inpsort), (int)inplast, 
+			    (long)(inpp - inpsort), (int)inplast,
 			    (int)((inpp - inpsort) * 100 / inplast));
 			got_siginfo = 0;
 		}
@@ -230,7 +230,7 @@ pass2(void)
 	 * Byte swapping in directory entries, if needed, has been done.
 	 * Now rescan dirs for pass2check()
 	 */
-	if (do_dirswap) { 
+	if (do_dirswap) {
 		do_dirswap = 0;
 		for (inpp = inpsort; inpp < inpend; inpp++) {
 			inp = *inpp;
@@ -341,7 +341,7 @@ pass2check(struct inodesc *idesc)
 		dirp->d_type = inoinfo(iswap32(dirp->d_ino))->ino_type;
 		ret |= ALTERED;
 	}
-	/* 
+	/*
 	 * check for "."
 	 */
 	if (idesc->id_entryno != 0)

Index: src/sbin/fsck_ffs/pass4.c
diff -u src/sbin/fsck_ffs/pass4.c:1.30 src/sbin/fsck_ffs/pass4.c:1.31
--- src/sbin/fsck_ffs/pass4.c:1.30	Sat Jan 14 12:12:50 2023
+++ src/sbin/fsck_ffs/pass4.c	Tue Jul  4 20:40:53 2023
@@ -1,4 +1,4 @@
-/*	$NetBSD: pass4.c,v 1.30 2023/01/14 12:12:50 christos Exp $	*/
+/*	$NetBSD: pass4.c,v 1.31 2023/07/04 20:40:53 riastradh Exp $	*/
 
 /*
  * Copyright (c) 1980, 1986, 1993
@@ -34,7 +34,7 @@
 #if 0
 static char sccsid[] = "@(#)pass4.c	8.4 (Berkeley) 4/28/95";
 #else
-__RCSID("$NetBSD: pass4.c,v 1.30 2023/01/14 12:12:50 christos Exp $");
+__RCSID("$NetBSD: pass4.c,v 1.31 2023/07/04 20:40:53 riastradh Exp $");
 #endif
 #endif /* not lint */
 
@@ -196,7 +196,7 @@ pass4check(struct inodesc *idesc)
 				n_blks--;
 				if (idesc->id_type != SNAP) {
 					update_uquot(idesc->id_number,
-					    idesc->id_uid, idesc->id_gid, 
+					    idesc->id_uid, idesc->id_gid,
 					    -btodb(sblock->fs_fsize), 0);
 				}
 				if (idesc->id_numfrags != sblock->fs_frag &&

Index: src/sbin/fsck_ffs/pass6.c
diff -u src/sbin/fsck_ffs/pass6.c:1.4 src/sbin/fsck_ffs/pass6.c:1.5
--- src/sbin/fsck_ffs/pass6.c:1.4	Sun Aug 26 09:34:17 2012
+++ src/sbin/fsck_ffs/pass6.c	Tue Jul  4 20:40:53 2023
@@ -1,4 +1,5 @@
-/* $NetBSD: pass6.c,v 1.4 2012/08/26 09:34:17 dholland Exp $ */
+/* $NetBSD: pass6.c,v 1.5 2023/07/04 20:40:53 riastradh Exp $ */
+
 /*-
   * Copyright (c) 2010 Manuel Bouyer
   * All rights reserved.
@@ -52,7 +53,7 @@ pass6(void)
 	if ((sblock->fs_flags & FS_DOQUOTA2) == 0)
 		return;
 
-	for (i = 0; i < MAXQUOTAS; i++) {	
+	for (i = 0; i < MAXQUOTAS; i++) {
 		if ((sblock->fs_quota_flags & FS_Q2_DO_TYPE(i)) == 0 &&
 		    sblock->fs_quotafile[i] != 0) {
 			if (preen || reply(
@@ -87,4 +88,3 @@ pass6(void)
 	if (ret2 == 0)
 		quota2_check_usage(GRPQUOTA);
 }
-

Index: src/sbin/fsck_ffs/quota2.c
diff -u src/sbin/fsck_ffs/quota2.c:1.7 src/sbin/fsck_ffs/quota2.c:1.8
--- src/sbin/fsck_ffs/quota2.c:1.7	Sun Feb  3 03:19:26 2019
+++ src/sbin/fsck_ffs/quota2.c	Tue Jul  4 20:40:53 2023
@@ -1,4 +1,5 @@
-/* $NetBSD: quota2.c,v 1.7 2019/02/03 03:19:26 mrg Exp $ */
+/* $NetBSD: quota2.c,v 1.8 2023/07/04 20:40:53 riastradh Exp $ */
+
 /*-
   * Copyright (c) 2010 Manuel Bouyer
   * All rights reserved.
@@ -122,7 +123,7 @@ quota2_alloc_quota(union dinode * dp, st
 	q2h->q2h_entries[uid & q2h_hash_mask] = iswap64(off);
 	dirty(bp);
 	dirty(hbp);
-	
+
 	if (bp != hbp)
 		bp->b_flags &= ~B_INUSE;
 	return 0;
@@ -247,7 +248,7 @@ quota2_check_inode(int type)
 	const int quota2_hash_size = 1 << q2h_hash_shift;
 	const int quota2_full_header_size = sizeof(struct quota2_header) +
 	    sizeof(q2h->q2h_entries[0]) * quota2_hash_size;
-	
+
 	if ((sblock->fs_quota_flags & FS_Q2_DO_TYPE(type)) == 0)
 		return 0;
 	if (sblock->fs_quotafile[type] != 0) {
@@ -361,7 +362,7 @@ alloc:
 		for (j = 0; j < nq2e; j++)
 			setbit(quotamap[i], j);
 	}
-		
+
 	/* check that all entries are in the lists (and only once) */
 	i = -1;
 	ret = quota2_walk_list(dp, hbp, &q2h->q2h_free, &i, quota2_list_check);
@@ -417,7 +418,7 @@ struct qcheck_arg {
 	const char *capstrtype;
 	struct uquot_hash *uquot_hash;
 };
-	
+
 static int quota2_list_qcheck(uint64_t *, struct quota2_entry *, uint64_t,
     void *);
 static int
@@ -437,8 +438,8 @@ quota2_list_qcheck(uint64_t *offp, struc
 		uq = &uq_null;
 	else
 		remove_uquot(a->uquot_hash, uq);
-		
-	if (iswap64(q2e->q2e_val[QL_BLOCK].q2v_cur) == uq->uq_b && 
+
+	if (iswap64(q2e->q2e_val[QL_BLOCK].q2v_cur) == uq->uq_b &&
 	    iswap64(q2e->q2e_val[QL_FILE].q2v_cur) == uq->uq_i)
 		return 0;
 	pwarn("%s QUOTA MISMATCH FOR ID %d: %" PRIu64 "/%" PRIu64 " SHOULD BE "
@@ -461,7 +462,7 @@ quota2_check_usage(int type)
 {
 	const char *strtype = (type == USRQUOTA) ? "user" : "group";
 	const char *capstrtype = (type == USRQUOTA) ? "USER" : "GROUP";
-	
+
 	struct bufarea *hbp;
 	union dinode *dp;
 	struct quota2_header *q2h;
@@ -488,7 +489,7 @@ quota2_check_usage(int type)
 		if (ret)
 			return ret;
 	}
-	
+
 	for (i = 0; i < quota2_hash_size; i++) {
 		struct uquot *uq;
 		SLIST_FOREACH(uq, &a.uquot_hash[i], uq_entries) {

Index: src/sbin/fsck_ffs/setup.c
diff -u src/sbin/fsck_ffs/setup.c:1.107 src/sbin/fsck_ffs/setup.c:1.108
--- src/sbin/fsck_ffs/setup.c:1.107	Tue Jul  4 20:40:22 2023
+++ src/sbin/fsck_ffs/setup.c	Tue Jul  4 20:40:53 2023
@@ -1,4 +1,4 @@
-/*	$NetBSD: setup.c,v 1.107 2023/07/04 20:40:22 riastradh Exp $	*/
+/*	$NetBSD: setup.c,v 1.108 2023/07/04 20:40:53 riastradh Exp $	*/
 
 /*
  * Copyright (c) 1980, 1986, 1993
@@ -34,7 +34,7 @@
 #if 0
 static char sccsid[] = "@(#)setup.c	8.10 (Berkeley) 5/9/95";
 #else
-__RCSID("$NetBSD: setup.c,v 1.107 2023/07/04 20:40:22 riastradh Exp $");
+__RCSID("$NetBSD: setup.c,v 1.108 2023/07/04 20:40:53 riastradh Exp $");
 #endif
 #endif /* not lint */
 
@@ -182,7 +182,7 @@ setup(const char *dev, const char *origd
 
 	if (!quota2_check_doquota())
 		doskipclean = 0;
-		
+
 	/* ffs_superblock_layout() == 2 */
 	if (sblock->fs_magic != FS_UFS1_MAGIC ||
 	    (sblock->fs_old_flags & FS_FLAGS_UPDATED) != 0) {
@@ -209,7 +209,7 @@ setup(const char *dev, const char *origd
 			 * so we don't bother to re-read the superblock from
 			 * the journal.
 			 * XXX, instead we could re-read the superblock and
-			 * then not force doskipclean = 0 
+			 * then not force doskipclean = 0
 			 */
 		}
 	}
@@ -297,7 +297,7 @@ setup(const char *dev, const char *origd
 		}
 	}
 	if (!is_ufs2 && sblock->fs_old_postblformat != FS_42POSTBLFMT &&
-	    (sblock->fs_old_interleave < 1 || 
+	    (sblock->fs_old_interleave < 1 ||
 	    sblock->fs_old_interleave > sblock->fs_old_nsect)) {
 		pwarn("IMPOSSIBLE INTERLEAVE=%d IN SUPERBLOCK",
 			sblock->fs_old_interleave);
@@ -310,7 +310,7 @@ setup(const char *dev, const char *origd
 		}
 	}
 	if (!is_ufs2 && sblock->fs_old_postblformat != FS_42POSTBLFMT &&
-	    (sblock->fs_old_npsect < sblock->fs_old_nsect || 
+	    (sblock->fs_old_npsect < sblock->fs_old_nsect ||
 	    sblock->fs_old_npsect > sblock->fs_old_nsect*2)) {
 		pwarn("IMPOSSIBLE NPSECT=%d IN SUPERBLOCK",
 			sblock->fs_old_npsect);
@@ -465,7 +465,7 @@ setup(const char *dev, const char *origd
 	    roundup2(sblock->fs_cssize, DEV_BSIZE));
 	if (sblock->fs_csp == NULL) {
 		pwarn("cannot alloc %u bytes for summary info\n",
-		    sblock->fs_cssize);	
+		    sblock->fs_cssize);
 		goto badsblabel;
 	}
 	memset(sblock->fs_csp, 0, sblock->fs_cssize);
@@ -530,7 +530,7 @@ setup(const char *dev, const char *origd
 	inpsort = calloc((unsigned)listmax, sizeof(*inpsort));
 	inphead = calloc((unsigned)numdirs, sizeof(*inphead));
 	if (inpsort == NULL || inphead == NULL) {
-		pwarn("cannot alloc %u bytes for inphead\n", 
+		pwarn("cannot alloc %u bytes for inphead\n",
 		    (unsigned)(numdirs * sizeof(struct inoinfo *)));
 		goto badsblabel;
 	}
@@ -549,7 +549,7 @@ setup(const char *dev, const char *origd
 		usedsoftdep = 0;
 
 #ifndef NO_APPLE_UFS
-	if (!forceimage && dkw.dkw_parent[0]) 
+	if (!forceimage && dkw.dkw_parent[0])
 		if (strcmp(dkw.dkw_ptype, DKW_PTYPE_APPLEUFS) == 0)
 			isappleufs = 1;
 
@@ -1067,7 +1067,6 @@ cmpsblks44(const struct fs *sb, struct f
 	return memcmp(sb, asb, sb->fs_sbsize);
 }
 
-
 static void
 badsb(int listerr, const char *s)
 {
@@ -1160,7 +1159,7 @@ check_snapinum(void)
 	uint32_t *snapinum = &sblock->fs_snapinum[0];
 
 	res = 0;
- 
+
 	if (isappleufs)
 		return 0;
 

Index: src/sbin/fsck_ffs/utilities.c
diff -u src/sbin/fsck_ffs/utilities.c:1.69 src/sbin/fsck_ffs/utilities.c:1.70
--- src/sbin/fsck_ffs/utilities.c:1.69	Tue Jul  4 20:40:22 2023
+++ src/sbin/fsck_ffs/utilities.c	Tue Jul  4 20:40:53 2023
@@ -1,4 +1,4 @@
-/*	$NetBSD: utilities.c,v 1.69 2023/07/04 20:40:22 riastradh Exp $	*/
+/*	$NetBSD: utilities.c,v 1.70 2023/07/04 20:40:53 riastradh Exp $	*/
 
 /*
  * Copyright (c) 1980, 1986, 1993
@@ -34,7 +34,7 @@
 #if 0
 static char sccsid[] = "@(#)utilities.c	8.6 (Berkeley) 5/19/95";
 #else
-__RCSID("$NetBSD: utilities.c,v 1.69 2023/07/04 20:40:22 riastradh Exp $");
+__RCSID("$NetBSD: utilities.c,v 1.70 2023/07/04 20:40:53 riastradh Exp $");
 #endif
 #endif /* not lint */
 
@@ -671,7 +671,7 @@ sb_oldfscompat_read(struct fs *fs, struc
 	    fs->fs_old_cstotal.cs_nifree;
 	fs->fs_cstotal.cs_nffree =
 	    fs->fs_old_cstotal.cs_nffree;
-	
+
 	fs->fs_maxbsize = fs->fs_bsize;
 	fs->fs_time = fs->fs_old_time;
 	fs->fs_size = fs->fs_old_size;
@@ -756,17 +756,17 @@ update_uquot(ino_t inum, uid_t uid, gid_
 		return;
 	if (is_quota_inode(inum))
 		return;
-	
+
 	if (uquot_user_hash == NULL)
 		return;
-		
+
 	if (uq_u == NULL || uq_u->uq_uid != uid)
 		uq_u = find_uquot(uquot_user_hash, uid, 1);
 	uq_u->uq_b += bchange;
 	uq_u->uq_i += ichange;
 	if (uq_g == NULL || uq_g->uq_uid != gid)
 		uq_g = find_uquot(uquot_group_hash, gid, 1);
-	uq_g->uq_b += bchange;    
+	uq_g->uq_b += bchange;
 	uq_g->uq_i += ichange;
 }
 
@@ -779,11 +779,11 @@ is_quota_inode(ino_t inum)
 
 	if (sblock->fs_quota_magic != Q2_HEAD_MAGIC)
 		return 0;
-	
+
 	if (sblock->fs_quotafile[USRQUOTA] == inum)
 		return 1;
 
-	if (sblock->fs_quotafile[GRPQUOTA] == inum) 
+	if (sblock->fs_quotafile[GRPQUOTA] == inum)
 		return 1;
 
 	return 0;

Reply via email to