diff options
author | Giuseppe Di Natale <[email protected]> | 2017-03-09 17:40:21 -0800 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2017-03-09 17:40:21 -0800 |
commit | 589bb918ef39058b1f06da72092e895835a7aaff (patch) | |
tree | bc5cdc05e6f334fef7b20e2d6ec53fcb9bd7c605 /module/zfs/zfs_vnops.c | |
parent | c3d043817305efebce89db5d9146e70807c4043b (diff) |
Suppress cppcheck nullPointer error in zfs_write
Newer versions of cppcheck find the potential NULL pointer
bug in zfs_write(). The function is difficult to refactor without
extensive work, so suppress the potential NULL pointer error
which cannot occur for now.
Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Giuseppe Di Natale <[email protected]>
Closes #5882
Diffstat (limited to 'module/zfs/zfs_vnops.c')
-rw-r--r-- | module/zfs/zfs_vnops.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/module/zfs/zfs_vnops.c b/module/zfs/zfs_vnops.c index 2e5099574..502e8f4a2 100644 --- a/module/zfs/zfs_vnops.c +++ b/module/zfs/zfs_vnops.c @@ -829,6 +829,7 @@ zfs_write(struct inode *ip, uio_t *uio, int ioflag, cred_t *cr) aiov->iov_base != abuf->b_data)) { ASSERT(xuio); dmu_write(zsb->z_os, zp->z_id, woff, + // cppcheck-suppress nullPointer aiov->iov_len, aiov->iov_base, tx); dmu_return_arcbuf(abuf); xuio_stat_wbuf_copied(); |