Thread (2 messages) 2 messages, 2 authors, 2021-07-27

Re: [PATCH] xfs_repair: invalidate dirhash entry when junking dirent

From: Dave Chinner <david@fromorbit.com>
Date: 2021-07-27 22:17:26

On Tue, Jul 27, 2021 at 12:16:11PM -0700, Darrick J. Wong wrote:
From: Darrick J. Wong <djwong@kernel.org>

In longform_dir2_entry_check_data, we add the directory entries we find
to the incore dirent hash table after we've validated the name but
before we're totally done checking the entry.  This sequence is
necessary to detect all duplicated names in the directory.

Unfortunately, if we later decide to junk the ondisk dirent, we neglect
to mark the dirhash entry, so if the directory gets rebuilt, it will get
rebuilt with the entry that we rejected.

Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Makes sense.

Reviewed-by: Dave Chinner <redacted>
-- 
Dave Chinner
david@fromorbit.com
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help