From: Theodore Ts'o Date: Fri, 8 Nov 2002 20:35:13 +0000 (-0500) Subject: unix.c (PRS), journal.c: Set the default level of journal X-Git-Tag: E2FSPROGS-1_31~7 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5e72cdbeb9cfe32ddff1293cc672dcf66f4f2d5b;p=thirdparty%2Fe2fsprogs.git unix.c (PRS), journal.c: Set the default level of journal debugging to be 0, and allow the user to set the level of journal debugging by using the E2FSCK_JBD_DEBUG environment variable. --- diff --git a/e2fsck/ChangeLog b/e2fsck/ChangeLog index 8e32eeb3a..9c7a43c07 100644 --- a/e2fsck/ChangeLog +++ b/e2fsck/ChangeLog @@ -1,5 +1,10 @@ 2002-11-08 + * unix.c (PRS), journal.c: Set the default level of journal + debugging to be 0, and allow the user to set the level of + journal debugging by using the E2FSCK_JBD_DEBUG + environment variable. + * pass1.c (new_table_block), super.c (check_super_block), swapfs.c (swap_filesys): Clear EXT2_FLAG_MASTER_SB_ONLY to make sure the backup superblocks and group descriptors are diff --git a/e2fsck/journal.c b/e2fsck/journal.c index a6a8426c9..f3399f9c2 100644 --- a/e2fsck/journal.c +++ b/e2fsck/journal.c @@ -27,7 +27,6 @@ #ifdef CONFIG_JBD_DEBUG /* Enabled by configure --enable-jfs-debug */ static int bh_count = 0; -int journal_enable_debug = 2; #endif /* diff --git a/e2fsck/unix.c b/e2fsck/unix.c index bee663664..241f048fc 100644 --- a/e2fsck/unix.c +++ b/e2fsck/unix.c @@ -53,6 +53,10 @@ static char *bad_blocks_file = 0; e2fsck_t e2fsck_global_ctx; /* Try your very best not to use this! */ +#ifdef CONFIG_JBD_DEBUG /* Enabled by configure --enable-jfs-debug */ +int journal_enable_debug = -1; +#endif + static void usage(e2fsck_t ctx) { fprintf(stderr, @@ -727,6 +731,10 @@ static errcode_t PRS(int argc, char *argv[], e2fsck_t *ret_ctx) } else putenv (PATH_SET); } +#ifdef CONFIG_JBD_DEBUG + if (getenv("E2FSCK_JBD_DEBUG")) + journal_enable_debug = atoi(getenv("E2FSCK_JBD_DEBUG")); +#endif return 0; }