http://oss.sgi.com/bugzilla/show_bug.cgi?id=844
Eric Sandeen <sandeen-xfs@xxxxxxxxxxx> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |sandeen-xfs@xxxxxxxxxxx
--- Comment #3 from Eric Sandeen <sandeen-xfs@xxxxxxxxxxx> 2009-07-23 17:20:56
CST ---
longform_dir2_entry_check() calls longform_dir2_entry_check_data() which issues
that "junking block" message, and it sets *bpp (which is bplist[0]) to NULL
(minor note, I think this leaks a bit of memory).
In this case it's a single-block directory, the dir was found to have no data,
and so it was junked. In that case there's no point to checking the integrity
and in fact trying to do so is what segfaults, thanks to the NULL-setting
above.
So a simple patch like this avoids the segfault:
--- a/repair/phase6.c
+++ b/repair/phase6.c
@@ -2524,7 +2525,7 @@ longform_dir2_entry_check(xfs_mount_t *mp,
if (!dotdot_update) {
/* check btree and freespace */
- if (isblock) {
+ if (isblock && bplist[0]) {
xfs_dir2_block_tail_t *btp;
xfs_dir2_leaf_entry_t *blp;
However, it still takes 2 passes for repair to come up clean with this change.
The first pass ends with:
Phase 7 - verify and correct link counts...
resetting inode 3503084373 nlinks from 2 to 1
done
and then a subsequent run does:
Phase 7 - verify and correct link counts...
resetting inode 3503084373 nlinks from 1 to 2
done
and from then on it's clean. So need to see what's up with that, yet.
--
Configure bugmail: http://oss.sgi.com/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
|