| To: | xfs@xxxxxxxxxxx |
|---|---|
| Subject: | [PATCH 06/32] xfs: don't assert fail on bad inode numbers |
| From: | Dave Chinner <david@xxxxxxxxxxxxx> |
| Date: | Mon, 30 Sep 2013 13:15:18 +1000 |
| Delivered-to: | xfs@xxxxxxxxxxx |
| In-reply-to: | <1380510944-8571-1-git-send-email-david@xxxxxxxxxxxxx> |
| References: | <1380510944-8571-1-git-send-email-david@xxxxxxxxxxxxx> |
From: Dave Chinner <dchinner@xxxxxxxxxx>
Let the inode verifier do it's work by returning an error when we
fail to find correct magic numbers in an inode buffer.
Signed-off-by: Dave Chinner <dchinner@xxxxxxxxxx>
---
libxfs/xfs_inode_buf.c | 8 +++-----
1 file changed, 3 insertions(+), 5 deletions(-)
diff --git a/libxfs/xfs_inode_buf.c b/libxfs/xfs_inode_buf.c
index 6205318..b096f77 100644
--- a/libxfs/xfs_inode_buf.c
+++ b/libxfs/xfs_inode_buf.c
@@ -39,9 +39,8 @@ xfs_inobp_check(
i * mp->m_sb.sb_inodesize);
if (!dip->di_next_unlinked) {
xfs_alert(mp,
- "Detected bogus zero next_unlinked field in incore inode buffer 0x%p.",
- bp);
- ASSERT(dip->di_next_unlinked);
+ "Detected bogus zero next_unlinked field in inode %d buffer 0x%llx.",
+ i, (long long)bp->b_bn);
}
}
}
@@ -74,11 +73,10 @@ xfs_inode_buf_verify(
XFS_CORRUPTION_ERROR(__func__, XFS_ERRLEVEL_HIGH,
mp, dip);
#ifdef DEBUG
- xfs_emerg(mp,
+ xfs_alert(mp,
"bad inode magic/vsn daddr %lld #%d (magic=%x)",
(unsigned long long)bp->b_bn, i,
be16_to_cpu(dip->di_magic));
- ASSERT(0);
#endif
}
}
--
1.8.3.2
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | Re: [PATCH] xfsprogs: cleanup size/log setting flags of mkfs, Eric Sandeen |
|---|---|
| Next by Date: | [PATCH 01/32] xfsprogs: fix automatic dependency generation, Dave Chinner |
| Previous by Thread: | [PATCH 00/32] xfsprogs: V5 write support for xfs_db, Dave Chinner |
| Next by Thread: | [PATCH 01/32] xfsprogs: fix automatic dependency generation, Dave Chinner |
| Indexes: | [Date] [Thread] [Top] [All Lists] |