OSDN Git Service

dumpe2fs: Only print inline journal information if the journal is internal
authorTheodore Ts'o <tytso@mit.edu>
Sat, 15 Nov 2008 20:05:51 +0000 (15:05 -0500)
committerTheodore Ts'o <tytso@mit.edu>
Sat, 15 Nov 2008 20:05:51 +0000 (15:05 -0500)
Currently dumpe2fs displays an error if run on a filesystem with an
external journal.

Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
misc/dumpe2fs.c

index 9ef5476..61b82f6 100644 (file)
@@ -517,8 +517,9 @@ int main (int argc, char ** argv)
                        ext2fs_close(fs);
                        exit(0);
                }
-               if (fs->super->s_feature_compat &
-                     EXT3_FEATURE_COMPAT_HAS_JOURNAL)
+               if ((fs->super->s_feature_compat &
+                    EXT3_FEATURE_COMPAT_HAS_JOURNAL) &&
+                   (fs->super->s_journal_inum != 0))
                        print_inline_journal_information(fs);
                list_bad_blocks(fs, 0);
                if (header_only) {