aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Johnston <markj@FreeBSD.org>2026-05-12 17:47:11 +0000
committerMark Johnston <markj@FreeBSD.org>2026-05-12 20:05:19 +0000
commit3cd3900b690d8296094921cec844da3f72d30cbb (patch)
treef1998353c9ec0ceeb234ca406577be93c2fd8e6d
parent237900f17f091d059a3ead6a5320285654f4bfa0 (diff)
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
-rw-r--r--sbin/fsck_ffs/fsck.h9
-rw-r--r--sbin/fsck_ffs/gjournal.c4
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