e2fsck: don't check inode flag values for deleted inodes

Commit 47b8941774df "e2fsck: make sure system.data xattr is present"
exposed a bug in e2fsck's pass 1 handling which caused the xfstests's
generic/079 to fail if the inline_data feature was enabled.  The
problem was that e2fsck was checking if an inode with inline data had
the system.xattr EA before checking to see if that inode was still in
use --- and this invariant isn't necessarily true for deleted inodes.
There were a number of other checks that were done too early that
could also potentially cause false positive complaints, although those
would normally only happen if a now-unused portion of the inode table
had gotten corrupted, or if tune2fs had disabled a particular file
system feature and there old, deleted inodes that had values
inconsistent with the new file system configuration.

Reported-by: Eric Whitney <enwlinux@gmail.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
1 file changed