gfs2-utils: master - fsck.gfs2: Free, don't invalidate, dinodes with bad depth

Bob Peterson rpeterso at fedoraproject.org
Tue Jan 26 21:11:15 UTC 2010


Gitweb:        http://git.fedorahosted.org/git/gfs2-utils.git?p=gfs2-utils.git;a=commitdiff;h=1aed3a973bb72e29e9d9d6cc0d1c26060db8080a
Commit:        1aed3a973bb72e29e9d9d6cc0d1c26060db8080a
Parent:        c73635bba7d4f1aab558dab181b311f1cc32a475
Author:        Bob Peterson <bob at ganesha.peterson>
AuthorDate:    Mon Jan 25 14:58:36 2010 -0600
Committer:     Bob Peterson <rpeterso at redhat.com>
CommitterDate: Tue Jan 26 15:09:52 2010 -0600

fsck.gfs2: Free, don't invalidate, dinodes with bad depth

This patch makes fsck.gfs2 free up dinodes with an invalid depth
rather than marking them invalid.  If we mark them invalid, the
invalid depth itself will confuse the code that later tries to free
the metadata associated with the bad dinode.

rhbz#455300
---
 gfs2/fsck/pass1.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/gfs2/fsck/pass1.c b/gfs2/fsck/pass1.c
index 1d33bd3..3343fed 100644
--- a/gfs2/fsck/pass1.c
+++ b/gfs2/fsck/pass1.c
@@ -1023,7 +1023,7 @@ static int handle_di(struct gfs2_sbd *sdp, struct gfs2_buffer_head *bh)
 				 ip->i_di.di_depth,
 				 (1 >> (ip->i_di.di_size/sizeof(uint64_t))));
 			if(fsck_blockmap_set(ip, block, _("bad depth"),
-					     gfs2_meta_inval)) {
+					     gfs2_block_free)) {
 				stack;
 				fsck_inode_put(&ip);
 				return -1;


More information about the cluster-commits mailing list