diff options
author | James Morris <james.l.morris@oracle.com> | 2017-03-28 11:03:35 +1100 |
---|---|---|
committer | James Morris <james.l.morris@oracle.com> | 2017-03-28 11:03:35 +1100 |
commit | 840c91dc6a13b160f5b6e5c79c430dffac11c945 (patch) | |
tree | 5309824f4531b2611a575e7971a935d2e95feb02 /net/ipv6/tcp_ipv6.c | |
parent | 3dfc9b02864b19f4dab376f14479ee4ad1de6c9e (diff) | |
parent | c02ed2e75ef4c74e41e421acb4ef1494671585e8 (diff) |
update to v4.11-rc4 due to memory corruption bug in rc2
Diffstat (limited to 'net/ipv6/tcp_ipv6.c')
-rw-r--r-- | net/ipv6/tcp_ipv6.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/net/ipv6/tcp_ipv6.c b/net/ipv6/tcp_ipv6.c index 60a5295a7de6..49fa2e8c3fa9 100644 --- a/net/ipv6/tcp_ipv6.c +++ b/net/ipv6/tcp_ipv6.c @@ -391,10 +391,12 @@ static void tcp_v6_err(struct sk_buff *skb, struct inet6_skb_parm *opt, np = inet6_sk(sk); if (type == NDISC_REDIRECT) { - struct dst_entry *dst = __sk_dst_check(sk, np->dst_cookie); + if (!sock_owned_by_user(sk)) { + struct dst_entry *dst = __sk_dst_check(sk, np->dst_cookie); - if (dst) - dst->ops->redirect(dst, sk, skb); + if (dst) + dst->ops->redirect(dst, sk, skb); + } goto out; } |