You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

28 lines
984 B

This patch is not yet upstream; there are missing braces under
the if (!no_modify && !zap_log) case so that a repair which fails
xlog_find_tail() will not be repairable, because -L will not be
able to zero out the log.
Reported-by: Xiao Yang <yangx.jy@cn.fujitsu.com>
Signed-off-by: Xiao Yang <yangx.jy@cn.fujitsu.com>
Reviewed-by: Eric Sandeen <sandeen@redhat.com>
Index: xfsprogs-4.5.0/repair/phase2.c
===================================================================
--- xfsprogs-4.5.0.orig/repair/phase2.c
+++ xfsprogs-4.5.0/repair/phase2.c
@@ -78,12 +78,13 @@ zero_log(
do_warn(
_("zero_log: cannot find log head/tail (xlog_find_tail=%d)\n"),
error);
- if (!no_modify && !zap_log)
+ if (!no_modify && !zap_log) {
do_warn(_(
"ERROR: The log head and/or tail cannot be discovered. Attempt to mount the\n"
"filesystem to replay the log or use the -L option to destroy the log and\n"
"attempt a repair.\n"));
exit(2);
+ }
} else {
if (verbose) {
do_log(