]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
fsck: remove unnecessary fsck.h
authorKarel Zak <kzak@redhat.com>
Mon, 20 Feb 2012 16:36:54 +0000 (17:36 +0100)
committerKarel Zak <kzak@redhat.com>
Tue, 20 Mar 2012 10:22:09 +0000 (11:22 +0100)
Signed-off-by: Karel Zak <kzak@redhat.com>
fsck/Makefile.am
fsck/fsck.c
fsck/fsck.h [deleted file]

index 020df83f966fb9944897f6fe6c9f19f6a70dbab3..e9fe4578c3887fbaf1d36242b6c82b355875ddc6 100644 (file)
@@ -3,6 +3,6 @@ include $(top_srcdir)/config/include-Makefile.am
 sbin_PROGRAMS = fsck
 dist_man_MANS = fsck.8
 
-fsck_SOURCES = fsck.c fsck.h
+fsck_SOURCES = fsck.c
 fsck_LDADD = $(ul_libmount_la) $(ul_libblkid_la)
 fsck_CFLAGS = $(AM_CFLAGS) -I$(ul_libmount_incdir) -I$(ul_libblkid_incdir)
index cbf74dcf4a1c0d26fc1bc9e813c4c29a6c0f9bd0..defbdae7a41acc93e54dec31dc0e0626a889cfd2 100644 (file)
 #include "pathnames.h"
 #include "exitcodes.h"
 #include "c.h"
-#include "fsck.h"
 
 #define XALLOC_EXIT_CODE       FSCK_EX_ERROR
 #include "xalloc.h"
 
+#ifndef DEFAULT_FSTYPE
+# define DEFAULT_FSTYPE        "ext2"
+#endif
+
+#define MAX_DEVICES 32
+#define MAX_ARGS 32
+
 static const char *ignored_types[] = {
        "ignore",
        "iso9660",
@@ -75,7 +81,36 @@ static const char *really_wanted[] = {
        NULL
 };
 
-#define BASE_MD "/dev/md"
+/*
+ * Internal structure for mount tabel entries.
+ */
+struct fsck_fs_data
+{
+       const char      *device;
+       dev_t           disk;
+       unsigned int    stacked:1,
+                       done:1,
+                       eval_device:1;
+};
+
+/*
+ * Structure to allow exit codes to be stored
+ */
+struct fsck_instance {
+       int     pid;
+       int     flags;          /* FLAG_{DONE|PROGRESS} */
+       int     lock;           /* flock()ed whole disk file descriptor or -1 */
+       int     exit_status;
+       time_t  start_time;
+       char *  prog;
+       char *  type;
+
+       struct libmnt_fs *fs;
+       struct fsck_instance *next;
+};
+
+#define FLAG_DONE 1
+#define FLAG_PROGRESS 2
 
 /*
  * Global variables for options
@@ -434,7 +469,7 @@ static char *find_fsck(const char *type)
        return(s ? prog : NULL);
 }
 
-static int progress_active(NOARGS)
+static int progress_active(void)
 {
        struct fsck_instance *inst;
 
@@ -1222,7 +1257,7 @@ static void __attribute__((__noreturn__)) usage(void)
        exit(FSCK_EX_USAGE);
 }
 
-static void signal_cancel(int sig FSCK_ATTR((unused)))
+static void signal_cancel(int sig __attribute__((__unused__)))
 {
        cancel_requested++;
 }
diff --git a/fsck/fsck.h b/fsck/fsck.h
deleted file mode 100644 (file)
index ddda584..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * fsck.h
- */
-
-#include <time.h>
-
-#ifdef __STDC__
-#define NOARGS void
-#else
-#define NOARGS
-#endif
-
-#ifdef __GNUC__
-#define FSCK_ATTR(x) __attribute__(x)
-#else
-#define FSCK_ATTR(x)
-#endif
-
-
-#ifndef DEFAULT_FSTYPE
-#define DEFAULT_FSTYPE "ext2"
-#endif
-
-#define MAX_DEVICES 32
-#define MAX_ARGS 32
-
-/*
- * Internal structure for mount tabel entries.
- */
-
-struct fsck_fs_data
-{
-       const char      *device;
-       dev_t           disk;
-       unsigned int    stacked:1,
-                       done:1,
-                       eval_device:1;
-};
-
-#define FLAG_DONE 1
-#define FLAG_PROGRESS 2
-
-/*
- * Structure to allow exit codes to be stored
- */
-struct fsck_instance {
-       int     pid;
-       int     flags;
-       int     lock;           /* flock()ed whole disk file descriptor or -1 */
-       int     exit_status;
-       time_t  start_time;
-       char *  prog;
-       char *  type;
-       struct libmnt_fs *fs;
-       struct fsck_instance *next;
-};
-
-extern char *base_device(const char *device);
-extern const char *identify_fs(const char *fs_name, const char *fs_types);
-