diff options
author | David Chinner <dgc@sgi.com> | 2008-04-09 22:22:17 -0400 |
---|---|---|
committer | Lachlan McIlroy <lachlan@redback.melbourne.sgi.com> | 2008-04-17 22:00:24 -0400 |
commit | d64e31a2f53cdcb2f95b782196faacb0995ca0c0 (patch) | |
tree | d13230aeeb739f263305c686168823e161bdf619 /fs/xfs/xfs_vnodeops.c | |
parent | 556b8b166c9514b5f940047a41dad8fe8cd9a778 (diff) |
[XFS] Ensure errors from xfs_bdstrat() are correctly checked.
xfsbdstrat() is declared to return an error. That is never checked because
the error is propagated by the xfs_buf_t that is passed through the
function.
Mark xfsbdstrat() as returning void and comment the prototype on the
methods needed for error checking.
SGI-PV: 980084
SGI-Modid: xfs-linux-melb:xfs-kern:30823a
Signed-off-by: David Chinner <dgc@sgi.com>
Signed-off-by: Niv Sardi <xaiki@sgi.com>
Signed-off-by: Lachlan McIlroy <lachlan@sgi.com>
Diffstat (limited to 'fs/xfs/xfs_vnodeops.c')
-rw-r--r-- | fs/xfs/xfs_vnodeops.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/fs/xfs/xfs_vnodeops.c b/fs/xfs/xfs_vnodeops.c index ca38fb9a9937..dd4621e0ab3b 100644 --- a/fs/xfs/xfs_vnodeops.c +++ b/fs/xfs/xfs_vnodeops.c | |||
@@ -3825,7 +3825,8 @@ xfs_zero_remaining_bytes( | |||
3825 | XFS_BUF_READ(bp); | 3825 | XFS_BUF_READ(bp); |
3826 | XFS_BUF_SET_ADDR(bp, XFS_FSB_TO_DB(ip, imap.br_startblock)); | 3826 | XFS_BUF_SET_ADDR(bp, XFS_FSB_TO_DB(ip, imap.br_startblock)); |
3827 | xfsbdstrat(mp, bp); | 3827 | xfsbdstrat(mp, bp); |
3828 | if ((error = xfs_iowait(bp))) { | 3828 | error = xfs_iowait(bp); |
3829 | if (error) { | ||
3829 | xfs_ioerror_alert("xfs_zero_remaining_bytes(read)", | 3830 | xfs_ioerror_alert("xfs_zero_remaining_bytes(read)", |
3830 | mp, bp, XFS_BUF_ADDR(bp)); | 3831 | mp, bp, XFS_BUF_ADDR(bp)); |
3831 | break; | 3832 | break; |
@@ -3837,7 +3838,8 @@ xfs_zero_remaining_bytes( | |||
3837 | XFS_BUF_UNREAD(bp); | 3838 | XFS_BUF_UNREAD(bp); |
3838 | XFS_BUF_WRITE(bp); | 3839 | XFS_BUF_WRITE(bp); |
3839 | xfsbdstrat(mp, bp); | 3840 | xfsbdstrat(mp, bp); |
3840 | if ((error = xfs_iowait(bp))) { | 3841 | error = xfs_iowait(bp); |
3842 | if (error) { | ||
3841 | xfs_ioerror_alert("xfs_zero_remaining_bytes(write)", | 3843 | xfs_ioerror_alert("xfs_zero_remaining_bytes(write)", |
3842 | mp, bp, XFS_BUF_ADDR(bp)); | 3844 | mp, bp, XFS_BUF_ADDR(bp)); |
3843 | break; | 3845 | break; |