Skip to content

Commit

Permalink
[XFS] Check return value of xfs_buf_get_noaddr()
Browse files Browse the repository at this point in the history
We check the return value of all other calls to xfs_buf_get_noaddr().
Make sense to do it here too.

Signed-off-by: Lachlan McIlroy <lachlan@sgi.com>
Reviewed-by: Christoph Hellwig <hch@infradead.org>
Reviewed-by: Eric Sandeen <sandeen@sandeen.net>
  • Loading branch information
Lachlan McIlroy committed Dec 5, 2008
1 parent 6a0775a commit c642261
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions fs/xfs/xfs_vnodeops.c
Original file line number Diff line number Diff line change
Expand Up @@ -3034,6 +3034,8 @@ xfs_zero_remaining_bytes(
bp = xfs_buf_get_noaddr(mp->m_sb.sb_blocksize,
XFS_IS_REALTIME_INODE(ip) ?
mp->m_rtdev_targp : mp->m_ddev_targp);
if (!bp)
return XFS_ERROR(ENOMEM);

for (offset = startoff; offset <= endoff; offset = lastoffset + 1) {
offset_fsb = XFS_B_TO_FSBT(mp, offset);
Expand Down

0 comments on commit c642261

Please sign in to comment.