diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2017-09-20 20:14:51 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2017-12-02 20:38:08 -0500 |
commit | 7edffd25be336ecc9e82d36ef53f5c9ab552e01f (patch) | |
tree | 4d39f163b41979cfd318857caef3e4b636edbebe /net/netfilter | |
parent | 956a27ecfad51048c7614ec256c638f166bd8db3 (diff) | |
download | linux-7edffd25be336ecc9e82d36ef53f5c9ab552e01f.tar.bz2 |
ipvs: switch to sock_recvmsg()
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'net/netfilter')
-rw-r--r-- | net/netfilter/ipvs/ip_vs_sync.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/net/netfilter/ipvs/ip_vs_sync.c b/net/netfilter/ipvs/ip_vs_sync.c index 9ee71cb276d7..fbaf3bd05b2e 100644 --- a/net/netfilter/ipvs/ip_vs_sync.c +++ b/net/netfilter/ipvs/ip_vs_sync.c @@ -1636,17 +1636,14 @@ static int ip_vs_receive(struct socket *sock, char *buffer, const size_t buflen) { struct msghdr msg = {NULL,}; - struct kvec iov; + struct kvec iov = {buffer, buflen}; int len; EnterFunction(7); /* Receive a packet */ - iov.iov_base = buffer; - iov.iov_len = (size_t)buflen; - - len = kernel_recvmsg(sock, &msg, &iov, 1, buflen, MSG_DONTWAIT); - + iov_iter_kvec(&msg.msg_iter, READ | ITER_KVEC, &iov, 1, buflen); + len = sock_recvmsg(sock, &msg, MSG_DONTWAIT); if (len < 0) return len; |