diff options
author | Nathan Scott <nathans@sgi.com> | 2006-03-17 01:26:04 -0500 |
---|---|---|
committer | Nathan Scott <nathans@sgi.com> | 2006-03-17 01:26:04 -0500 |
commit | b12dd34298cf0cff9f337f667045335140873039 (patch) | |
tree | 0f2ef353bc17f247e538a28137a0a3f8ad3b5e0e /fs/xfs/xfs_itable.c | |
parent | 2ddd5928d01ca8eb49f55166411b64a5844a8959 (diff) |
[XFS] Fix an infinite loop issue in bulkstat when a corrupt inode is
detected. Thanks to Roger Willcocks.
SGI-PV: 951054
SGI-Modid: xfs-linux-melb:xfs-kern:25477a
Signed-off-by: Nathan Scott <nathans@sgi.com>
Diffstat (limited to 'fs/xfs/xfs_itable.c')
-rw-r--r-- | fs/xfs/xfs_itable.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/fs/xfs/xfs_itable.c b/fs/xfs/xfs_itable.c index c59450e1be40..32247b6bfee7 100644 --- a/fs/xfs/xfs_itable.c +++ b/fs/xfs/xfs_itable.c | |||
@@ -562,7 +562,8 @@ xfs_bulkstat( | |||
562 | if (bp) | 562 | if (bp) |
563 | xfs_buf_relse(bp); | 563 | xfs_buf_relse(bp); |
564 | error = xfs_itobp(mp, NULL, ip, | 564 | error = xfs_itobp(mp, NULL, ip, |
565 | &dip, &bp, bno); | 565 | &dip, &bp, bno, |
566 | XFS_IMAP_BULKSTAT); | ||
566 | if (!error) | 567 | if (!error) |
567 | clustidx = ip->i_boffset / mp->m_sb.sb_inodesize; | 568 | clustidx = ip->i_boffset / mp->m_sb.sb_inodesize; |
568 | kmem_zone_free(xfs_inode_zone, ip); | 569 | kmem_zone_free(xfs_inode_zone, ip); |
@@ -570,6 +571,8 @@ xfs_bulkstat( | |||
570 | mp, XFS_ERRTAG_BULKSTAT_READ_CHUNK, | 571 | mp, XFS_ERRTAG_BULKSTAT_READ_CHUNK, |
571 | XFS_RANDOM_BULKSTAT_READ_CHUNK)) { | 572 | XFS_RANDOM_BULKSTAT_READ_CHUNK)) { |
572 | bp = NULL; | 573 | bp = NULL; |
574 | ubleft = 0; | ||
575 | rval = error; | ||
573 | break; | 576 | break; |
574 | } | 577 | } |
575 | } | 578 | } |