]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commitdiff
mdrestore: Declare boolean variables with bool type
authorChandan Babu R <chandan.babu@oracle.com>
Mon, 6 Nov 2023 13:10:46 +0000 (18:40 +0530)
committerCarlos Maiolino <cem@kernel.org>
Tue, 21 Nov 2023 13:09:36 +0000 (14:09 +0100)
Reviewed-by: "Darrick J. Wong" <djwong@kernel.org>
Signed-off-by: Chandan Babu R <chandan.babu@oracle.com>
Signed-off-by: Carlos Maiolino <cem@kernel.org>
mdrestore/xfs_mdrestore.c

index 481dd00c2e710846e73175485dd69d55f28276e7..ca28c48e0e5b753ccbe29b7b612d56e67913f8f0 100644 (file)
@@ -7,9 +7,9 @@
 #include "libxfs.h"
 #include "xfs_metadump.h"
 
-static int     show_progress = 0;
-static int     show_info = 0;
-static int     progress_since_warning = 0;
+static bool    show_progress = false;
+static bool    show_info = false;
+static bool    progress_since_warning = false;
 
 static void
 fatal(const char *msg, ...)
@@ -35,7 +35,7 @@ print_progress(const char *fmt, ...)
 
        printf("\r%-59s", buf);
        fflush(stdout);
-       progress_since_warning = 1;
+       progress_since_warning = true;
 }
 
 /*
@@ -202,10 +202,10 @@ main(
        while ((c = getopt(argc, argv, "giV")) != EOF) {
                switch (c) {
                        case 'g':
-                               show_progress = 1;
+                               show_progress = true;
                                break;
                        case 'i':
-                               show_info = 1;
+                               show_info = true;
                                break;
                        case 'V':
                                printf("%s version %s\n", progname, VERSION);