aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/net/sctp/socket.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-02-11 09:26:45 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-02-11 09:26:45 +0100
commitc744ca39f28f9a1e94a62ba02483619925d25ddc (patch)
treebfcd445d31c88130cb0833675e2c7ea1c40f47e0 /net/sctp/socket.c
parentserial: max310x: Correction of the initial setting of the MODE1 bits for various supported ICs. (diff)
parentLinux 5.0-rc6 (diff)
downloadwireguard-linux-c744ca39f28f9a1e94a62ba02483619925d25ddc.tar.xz
wireguard-linux-c744ca39f28f9a1e94a62ba02483619925d25ddc.zip
Merge 5.0-rc6 into tty-next
We need the tty fixes in here for other patches to be based on. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to '')
-rw-r--r--net/sctp/socket.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/net/sctp/socket.c b/net/sctp/socket.c
index f93c3cf9e567..65d6d04546ae 100644
--- a/net/sctp/socket.c
+++ b/net/sctp/socket.c
@@ -2027,7 +2027,7 @@ static int sctp_sendmsg(struct sock *sk, struct msghdr *msg, size_t msg_len)
struct sctp_endpoint *ep = sctp_sk(sk)->ep;
struct sctp_transport *transport = NULL;
struct sctp_sndrcvinfo _sinfo, *sinfo;
- struct sctp_association *asoc;
+ struct sctp_association *asoc, *tmp;
struct sctp_cmsgs cmsgs;
union sctp_addr *daddr;
bool new = false;
@@ -2053,7 +2053,7 @@ static int sctp_sendmsg(struct sock *sk, struct msghdr *msg, size_t msg_len)
/* SCTP_SENDALL process */
if ((sflags & SCTP_SENDALL) && sctp_style(sk, UDP)) {
- list_for_each_entry(asoc, &ep->asocs, asocs) {
+ list_for_each_entry_safe(asoc, tmp, &ep->asocs, asocs) {
err = sctp_sendmsg_check_sflags(asoc, sflags, msg,
msg_len);
if (err == 0)