Home Home > GIT Browse > SLE12-SP5-AZURE
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichal Kubecek <mkubecek@suse.cz>2019-12-04 18:29:30 +0100
committerDenis Kirjanov <dkirjanov@suse.com>2019-12-11 16:09:13 +0300
commit12c818025f80ecdc1994acb49aca061fca0b0687 (patch)
tree23672b0003b6022eeb12eb374345d9eb2514549c
parent4305857dc904361ed60b24b96b4983684df3a49f (diff)
Update patches.suse/sctp-change-sctp_prot-.no_autobind-with-true.patch (networking-stable-19_10_24 bsc#1158082).
-rw-r--r--patches.suse/sctp-change-sctp_prot-.no_autobind-with-true.patch27
1 files changed, 22 insertions, 5 deletions
diff --git a/patches.suse/sctp-change-sctp_prot-.no_autobind-with-true.patch b/patches.suse/sctp-change-sctp_prot-.no_autobind-with-true.patch
index 2748385a70..6a166a97bb 100644
--- a/patches.suse/sctp-change-sctp_prot-.no_autobind-with-true.patch
+++ b/patches.suse/sctp-change-sctp_prot-.no_autobind-with-true.patch
@@ -1,9 +1,8 @@
From: Xin Long <lucien.xin@gmail.com>
-Date: Tue, 15 Oct 2019 15:24:38 +0800
Subject: sctp: change sctp_prot .no_autobind with true
+Patch-mainline: v5.4-rc4
Git-commit: 63dfb7938b13fa2c2fbcb45f34d065769eb09414
-Patch-mainline: 5.4-rc4
-References: networking-stable-19_10_24
+References: networking-stable-19_10_24 bsc#1158082
syzbot reported a memory leak:
@@ -43,10 +42,28 @@ Signed-off-by: Xin Long <lucien.xin@gmail.com>
Acked-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
+Signed-off-by: Michal Kubecek <mkubecek@suse.cz>
+
+SLE15: we need to check no_autobind socket flag in inet_dgram_connect() as,
+unlike in mainline, SCTP still uses this function.
+
---
- net/sctp/socket.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
+ net/ipv4/af_inet.c | 3 ++-
+ net/sctp/socket.c | 4 ++--
+ 2 files changed, 4 insertions(+), 3 deletions(-)
+--- a/net/ipv4/af_inet.c
++++ b/net/ipv4/af_inet.c
+@@ -535,7 +535,8 @@ int inet_dgram_connect(struct socket *sock, struct sockaddr *uaddr,
+ if (uaddr->sa_family == AF_UNSPEC)
+ return sk->sk_prot->disconnect(sk, flags);
+
+- if (!inet_sk(sk)->inet_num && inet_autobind(sk))
++ if (!inet_sk(sk)->inet_num && !sk->sk_prot->no_autobind &&
++ inet_autobind(sk))
+ return -EAGAIN;
+ return sk->sk_prot->connect(sk, uaddr, addr_len);
+ }
--- a/net/sctp/socket.c
+++ b/net/sctp/socket.c
@@ -8240,7 +8240,7 @@ struct proto sctp_prot = {