diff options
author | David S. Miller <davem@davemloft.net> | 2018-12-20 07:53:18 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-12-20 07:53:18 +0300 |
commit | d84e7bc0595a7e146ad0ddb80b240cea77825245 (patch) | |
tree | 90315f4d54fea915e0d5a344ffa3841759d7cc73 /net/rds | |
parent | c0fde870d96e42bbdcc0d9af7ae5e190c767aab8 (diff) | |
download | linux-d84e7bc0595a7e146ad0ddb80b240cea77825245.tar.xz |
rds: Fix warning.
>> net/rds/send.c:1109:42: warning: Using plain integer as NULL pointer
Fixes: ea010070d0a7 ("net/rds: fix warn in rds_message_alloc_sgs")
Reported-by: kbuild test robot <lkp@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/rds')
-rw-r--r-- | net/rds/send.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/net/rds/send.c b/net/rds/send.c index b39b30706210..3d822bad7de9 100644 --- a/net/rds/send.c +++ b/net/rds/send.c @@ -1109,9 +1109,11 @@ int rds_sendmsg(struct socket *sock, struct msghdr *msg, size_t payload_len) sock_flag(rds_rs_to_sk(rs), SOCK_ZEROCOPY)); int num_sgs = ceil(payload_len, PAGE_SIZE); int namelen; - struct rds_iov_vector_arr vct = {0}; + struct rds_iov_vector_arr vct; int ind; + memset(&vct, 0, sizeof(vct)); + /* expect 1 RDMA CMSG per rds_sendmsg. can still grow if more needed. */ vct.incr = 1; |