Fix a typo which could cause e2fsck to throw an I/O error while doubling
checking whether or not a special device file was really an inode.
Also, don't do this tests on symbolic links since for filesystems with a
large numbers of symlinks it could degrade performance and increases the
risk for false positives.
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
markers so it is clearer what e2fsck was doing when an I/O
error is reported.
+ *pass1.c (check_is_really_dir): Fix a typo which could cause
+ e2fsck to throw an I/O error while doubling checking
+ whether or not a special device file was really an inode.
+ Also, don't do this tests on symbolic links since for
+ filesystems with a large numbers of symlinks it could
+ degrade performance and increases the risk for false
+ positives.
+
2007-04-10 Jim Garlick <garlick@llnl.gov>
* pass1b.c (search_dirent_proc): if a file has multiple hard
int i, not_device = 0;
if (LINUX_S_ISDIR(inode->i_mode) || LINUX_S_ISREG(inode->i_mode) ||
- inode->i_block[0] == 0)
+ LINUX_S_ISLNK(inode->i_mode) || inode->i_block[0] == 0)
return;
- for (i=1; i < EXT2_N_BLOCKS; i++) {
+ for (i=0; i < EXT2_N_BLOCKS; i++) {
blk = inode->i_block[i];
if (!blk)
continue;
(inode->i_links_count == 1) && !not_device)
return;
- if (LINUX_S_ISLNK(inode->i_mode) && inode->i_links_count == 1)
- return;
-
old_op = ehandler_operation(_("reading directory block"));
retval = ext2fs_read_dir_block(ctx->fs, inode->i_block[0], buf);
ehandler_operation(0);