Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 12 May 2026 20:06:05 +0000
From:      Mark Johnston <markj@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: 3cd3900b690d - main - fsck_ffs: Avoid relying on param.h pollution from libufs.h
Message-ID:  <6a03882d.22d60.75b6446@gitrepo.freebsd.org>

index | next in thread | raw e-mail

The branch main has been updated by markj:

URL: https://cgit.FreeBSD.org/src/commit/?id=3cd3900b690d8296094921cec844da3f72d30cbb

commit 3cd3900b690d8296094921cec844da3f72d30cbb
Author:     Mark Johnston <markj@FreeBSD.org>
AuthorDate: 2026-05-12 17:47:11 +0000
Commit:     Mark Johnston <markj@FreeBSD.org>
CommitDate: 2026-05-12 20:05:19 +0000

    fsck_ffs: Avoid relying on param.h pollution from libufs.h
    
    - gjournal.c needs param.h to get a definition of isclr().
    - fsck.h needs signal.h for sig_atomic_t.
    
    Sort includes while here.
    
    Reviewed by:    kib
    MFC after:      1 week
    Differential Revision:  https://reviews.freebsd.org/D56858
---
 sbin/fsck_ffs/fsck.h     | 9 +++++----
 sbin/fsck_ffs/gjournal.c | 4 ++--
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/sbin/fsck_ffs/fsck.h b/sbin/fsck_ffs/fsck.h
index aaf02850f29a..ff2ac6305be2 100644
--- a/sbin/fsck_ffs/fsck.h
+++ b/sbin/fsck_ffs/fsck.h
@@ -62,13 +62,14 @@
 #ifndef _FSCK_H_
 #define	_FSCK_H_
 
-#include <unistd.h>
-#include <stdlib.h>
+#include <sys/queue.h>
+
+#include <signal.h>
 #include <stdio.h>
+#include <stdlib.h>
+#include <unistd.h>
 #include <libufs.h>
 
-#include <sys/queue.h>
-
 #define	MAXDUP		10	/* limit on dup blks (per inode) */
 #define	MAXBAD		10	/* limit on bad blks (per inode) */
 #define	MINBUFS		100	/* minimum number of buffers required */
diff --git a/sbin/fsck_ffs/gjournal.c b/sbin/fsck_ffs/gjournal.c
index b94f27758315..edbb2f373815 100644
--- a/sbin/fsck_ffs/gjournal.c
+++ b/sbin/fsck_ffs/gjournal.c
@@ -53,10 +53,10 @@
  * SUCH DAMAGE.
  */
 
-#include <sys/cdefs.h>
-#include <string.h>
+#include <sys/param.h>
 #include <sys/stat.h>
 #include <ufs/ffs/fs.h>
+#include <string.h>
 #include "fsck.h"
 
 void


home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?6a03882d.22d60.75b6446>