mirror of https://github.com/vitalif/e2fsprogs
e2fsck: if any problems are fixed in pass 0, check the whole file system
If there are any PREEN_OK problems fixed in check_super_block(), don't skip checking the full file system. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>maint-test
parent
bd1413d499
commit
7664c7538a
|
@ -189,8 +189,9 @@ struct resource_track {
|
|||
#define E2F_FLAG_GOT_DEVSIZE 0x0800 /* Device size has been fetched */
|
||||
#define E2F_FLAG_EXITING 0x1000 /* E2fsck exiting due to errors */
|
||||
#define E2F_FLAG_TIME_INSANE 0x2000 /* Time is insane */
|
||||
#define E2F_FLAG_PROBLEMS_FIXED 0x4000 /* At least one problem was fixed */
|
||||
|
||||
#define E2F_RESET_FLAGS (E2F_FLAG_TIME_INSANE)
|
||||
#define E2F_RESET_FLAGS (E2F_FLAG_TIME_INSANE | E2F_FLAG_PROBLEMS_FIXED)
|
||||
|
||||
/*
|
||||
* Defines for indicating the e2fsck pass number
|
||||
|
|
|
@ -1972,6 +1972,9 @@ int fix_problem(e2fsck_t ctx, problem_t code, struct problem_context *pctx)
|
|||
if (ptr->flags & PR_AFTER_CODE)
|
||||
answer = fix_problem(ctx, ptr->second_code, pctx);
|
||||
|
||||
if (answer && (ptr->prompt != PROMPT_NONE))
|
||||
ctx->flags |= E2F_FLAG_PROBLEMS_FIXED;
|
||||
|
||||
return answer;
|
||||
}
|
||||
|
||||
|
|
|
@ -337,6 +337,9 @@ static void check_if_skip(e2fsck_t ctx)
|
|||
int broken_system_clock;
|
||||
time_t lastcheck;
|
||||
|
||||
if (ctx->flags & E2F_FLAG_PROBLEMS_FIXED)
|
||||
return;
|
||||
|
||||
profile_get_boolean(ctx->profile, "options", "broken_system_clock",
|
||||
0, 0, &broken_system_clock);
|
||||
if (ctx->flags & E2F_FLAG_TIME_INSANE)
|
||||
|
|
Loading…
Reference in New Issue