Whamcloud - gitweb
e2fsck: reset lost_and_found after threads finish
authorWang Shilong <wshilong@ddn.com>
Fri, 20 Mar 2020 01:50:56 +0000 (09:50 +0800)
committerLi Dongyang <dongyangli@ddn.com>
Fri, 28 Apr 2023 00:47:13 +0000 (10:47 +1000)
This should not be kept, the reaons is similar to what
e2fsck_pass1 has done before.

E2fsprogs-commit: 10abbf8fd534d61c40fbf9699bf605ac6456b2e2

Change-Id: I0e431be7619720e31927ab1df7034aee1e3eb747
Signed-off-by: Wang Shilong <wshilong@ddn.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
e2fsck/pass1.c

index 59d12f1..65b49f2 100644 (file)
@@ -3061,6 +3061,11 @@ static int e2fsck_pass1_thread_join_one(e2fsck_t global_ctx, e2fsck_t thread_ctx
        /* threads might enable E2F_OPT_YES */
        global_ctx->options |= options;
        global_ctx->flags |= flags;
+       /*
+        * The l+f inode may have been cleared, so zap it now and
+        * later passes will recalculate it if necessary
+        */
+       global_ctx->lost_and_found = 0;
 
        retval = e2fsck_pass1_merge_fs(global_fs, thread_fs);
        if (retval) {