From: Theodore Ts'o Date: Sat, 23 Jun 2001 00:35:38 +0000 (-0400) Subject: super.c (release_inode_blocks): Don't try to release the blocks if the X-Git-Tag: WIP-20010620~4 X-Git-Url: https://git.whamcloud.com/gitweb?a=commitdiff_plain;h=42475e281d22dbefd7f0b399f6056f642fa0ab92;p=tools%2Fe2fsprogs.git super.c (release_inode_blocks): Don't try to release the blocks if the orphaned inode is a device file, symlink, or some other kind of special file that doesn't have a block list. --- diff --git a/e2fsck/ChangeLog b/e2fsck/ChangeLog index e2cb66c..782aec7 100644 --- a/e2fsck/ChangeLog +++ b/e2fsck/ChangeLog @@ -1,3 +1,9 @@ +2001-06-19 Theodore Tso + + * super.c (release_inode_blocks): Don't try to release the blocks + if the orphaned inode is a device file, symlink, or some + other kind of special file that doesn't have a block list. + 2001-06-15 Theodore Tso * Release of E2fsprogs 1.21 diff --git a/e2fsck/super.c b/e2fsck/super.c index 7a4a64a..1e67d1c 100644 --- a/e2fsck/super.c +++ b/e2fsck/super.c @@ -172,6 +172,9 @@ static int release_inode_blocks(e2fsck_t ctx, ext2_ino_t ino, errcode_t retval; struct process_block_struct pb; + if (!ext2fs_inode_has_valid_blocks(inode)) + return 0; + pb.buf = block_buf + 3 * ctx->fs->blocksize; pb.ctx = ctx; pb.abort = 0;