Skip to content

Commit 562640f

Browse files
author
Al Viro
committed
tipc_sendmsg(): pass msghdr instead of its ->msg_iov
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
1 parent e0eb093 commit 562640f

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

‎net/tipc/socket.c‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -700,15 +700,15 @@ static unsigned int tipc_poll(struct file *file, struct socket *sock,
700700
* tipc_sendmcast - send multicast message
701701
* @sock: socket structure
702702
* @seq: destination address
703-
* @iov: message data to send
703+
* @msg: message to send
704704
* @dsz: total length of message data
705705
* @timeo: timeout to wait for wakeup
706706
*
707707
* Called from function tipc_sendmsg(), which has done all sanity checks
708708
* Returns the number of bytes sent on success, or errno
709709
*/
710710
static int tipc_sendmcast(struct socket *sock, struct tipc_name_seq *seq,
711-
struct iovec *iov, size_t dsz, long timeo)
711+
struct msghdr *msg, size_t dsz, long timeo)
712712
{
713713
struct sock *sk = sock->sk;
714714
struct tipc_msg *mhdr = &tipc_sk(sk)->phdr;
@@ -727,7 +727,7 @@ static int tipc_sendmcast(struct socket *sock, struct tipc_name_seq *seq,
727727

728728
new_mtu:
729729
mtu = tipc_bclink_get_mtu();
730-
rc = tipc_msg_build(mhdr, iov, 0, dsz, mtu, &buf);
730+
rc = tipc_msg_build(mhdr, msg->msg_iov, 0, dsz, mtu, &buf);
731731
if (unlikely(rc < 0))
732732
return rc;
733733

@@ -951,7 +951,7 @@ static int tipc_sendmsg(struct kiocb *iocb, struct socket *sock,
951951
timeo = sock_sndtimeo(sk, m->msg_flags & MSG_DONTWAIT);
952952

953953
if (dest->addrtype == TIPC_ADDR_MCAST) {
954-
rc = tipc_sendmcast(sock, seq, iov, dsz, timeo);
954+
rc = tipc_sendmcast(sock, seq, m, dsz, timeo);
955955
goto exit;
956956
} else if (dest->addrtype == TIPC_ADDR_NAME) {
957957
u32 type = dest->addr.name.name.type;

0 commit comments

Comments
 (0)