| To: | xfs@xxxxxxxxxxx |
|---|---|
| Subject: | [PATCH 10/13] xfs_repair: clear need_root_dotdot if we rebuild the root dir |
| From: | Eric Sandeen <sandeen@xxxxxxxxxx> |
| Date: | Tue, 17 Mar 2015 15:33:12 -0500 |
| Delivered-to: | xfs@xxxxxxxxxxx |
| In-reply-to: | <1426624395-8258-1-git-send-email-sandeen@xxxxxxxxxx> |
| References: | <1426624395-8258-1-git-send-email-sandeen@xxxxxxxxxx> |
It's possible to enter longform_dir2_rebuild with need_root_dotdot
set; rebuilding it will add "..", and if need_root_dotdot stays set,
we'll add another ".." entry, causing a second repair to find and
fix that problem.
Signed-off-by: Eric Sandeen <sandeen@xxxxxxxxxx>
Reviewed-by: Carlos Maiolino <cmaiolino@xxxxxxxxxx>
---
repair/phase6.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/repair/phase6.c b/repair/phase6.c
index 0ec4f07..1728609 100644
--- a/repair/phase6.c
+++ b/repair/phase6.c
@@ -1354,6 +1354,9 @@ longform_dir2_rebuild(
libxfs_trans_commit(tp, XFS_TRANS_RELEASE_LOG_RES|XFS_TRANS_SYNC);
+ if (ino == mp->m_sb.sb_rootino)
+ need_root_dotdot = 0;
+
/* go through the hash list and re-add the inodes */
for (p = hashtab->first; p; p = p->nextbyorder) {
--
1.7.1
|
| Previous by Date: | [PATCH 09/13] libxfs: remove ASSERT on ftype read from disk, Eric Sandeen |
|---|---|
| Next by Date: | [PATCH 12/13] xfs_repair: don't clear . or .. in process_dir2_data, Eric Sandeen |
| Previous by Thread: | Re: PATCH 09/13 V2] libxfs: remove ASSERT on ftype read from disk, Brian Foster |
| Next by Thread: | [PATCH 12/13] xfs_repair: don't clear . or .. in process_dir2_data, Eric Sandeen |
| Indexes: | [Date] [Thread] [Top] [All Lists] |