]> git.ipfire.org Git - thirdparty/e2fsprogs.git/commitdiff
e2fsck: rename "bool" variables
authorAndreas Dilger <adilger@whamcloud.com>
Fri, 6 Jul 2012 01:44:20 +0000 (19:44 -0600)
committerTheodore Ts'o <tytso@mit.edu>
Sat, 14 Jul 2012 23:43:20 +0000 (19:43 -0400)
Since "bool" is a valid C type, declarations of the form "int bool"
will cause compiler errors if <stdbool.h> is included.  Rename these
variables to avoid this name clash.

Signed-off-by: Andreas Dilger <adilger@dilger.ca>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
e2fsck/e2fsck.h
e2fsck/pass1.c
e2fsck/problem.c
misc/e2image.c

index 971390e2401ff300e25eac93cc03ae1d7ce7c8de..420b67f559126436a74e04964c297d27f253b745 100644 (file)
@@ -466,7 +466,7 @@ extern void e2fsck_hide_quota(e2fsck_t ctx);
 /* pass1.c */
 extern void e2fsck_setup_tdb_icount(e2fsck_t ctx, int flags,
                                    ext2_icount_t *ret);
-extern void e2fsck_use_inode_shortcuts(e2fsck_t ctx, int bool);
+extern void e2fsck_use_inode_shortcuts(e2fsck_t ctx, int use_shortcuts);
 extern int e2fsck_pass1_check_device_inode(ext2_filsys fs,
                                           struct ext2_inode *inode);
 extern int e2fsck_pass1_check_symlink(ext2_filsys fs, ext2_ino_t ino,
index 72dcd971149fa90d143d9e163f9da69fe664cd40..78fbe8d0b75d2fd944a18407460dc6131275b365 100644 (file)
@@ -2822,11 +2822,11 @@ static void e2fsck_block_alloc_stats(ext2_filsys fs, blk64_t blk, int inuse)
        }
 }
 
-void e2fsck_use_inode_shortcuts(e2fsck_t ctx, int bool)
+void e2fsck_use_inode_shortcuts(e2fsck_t ctx, int use_shortcuts)
 {
        ext2_filsys fs = ctx->fs;
 
-       if (bool) {
+       if (use_shortcuts) {
                fs->get_blocks = pass1_get_blocks;
                fs->check_directory = pass1_check_directory;
                fs->read_inode = pass1_read_inode;
index 0948bdbb5f575dde49d0b1ae8b2d5aa11316ed0d..06640cbd6926c35fa9d31d50093c95e4fb68549f 100644 (file)
@@ -1789,11 +1789,11 @@ void clear_problem_context(struct problem_context *ctx)
 static void reconfigure_bool(e2fsck_t ctx, struct e2fsck_problem *ptr,
                             const char *key, int mask, const char *name)
 {
-       int     bool;
+       int     val;
 
-       bool = (ptr->flags & mask);
-       profile_get_boolean(ctx->profile, "problems", key, name, bool, &bool);
-       if (bool)
+       val = (ptr->flags & mask);
+       profile_get_boolean(ctx->profile, "problems", key, name, val, &val);
+       if (val)
                ptr->flags |= mask;
        else
                ptr->flags &= ~mask;
index 3a956efb8475671cfb1cc9c9fe67c2d2e38f42e1..e6ea52ae242ce80e7c6ee125faddce7a3008ea7c 100644 (file)
@@ -270,9 +270,9 @@ static errcode_t meta_read_inode(ext2_filsys fs EXT2FS_ATTR((unused)),
        return 0;
 }
 
-static void use_inode_shortcuts(ext2_filsys fs, int bool)
+static void use_inode_shortcuts(ext2_filsys fs, int use_shortcuts)
 {
-       if (bool) {
+       if (use_shortcuts) {
                fs->get_blocks = meta_get_blocks;
                fs->check_directory = meta_check_directory;
                fs->read_inode = meta_read_inode;