summaryrefslogtreecommitdiffstats
path: root/net/ipv6/syncookies.c
diff options
context:
space:
mode:
authorEric Dumazet <edumazet@google.com>2015-03-12 16:44:03 -0700
committerDavid S. Miller <davem@davemloft.net>2015-03-12 22:58:12 -0400
commitbd337c581b2b0d933d37f664bf55b342577fed3a (patch)
treeec450b42ebb3369f46c64f63a43a3915053205c6 /net/ipv6/syncookies.c
parent54720df130b3e6356391ed4f8a1a024318bcae23 (diff)
downloadlinux-bd337c581b2b0d933d37f664bf55b342577fed3a.tar.gz
linux-bd337c581b2b0d933d37f664bf55b342577fed3a.tar.bz2
linux-bd337c581b2b0d933d37f664bf55b342577fed3a.zip
ipv6: add missing ireq_net & ir_cookie initializations
I forgot to update dccp_v6_conn_request() & cookie_v6_check(). They both need to set ireq->ireq_net and ireq->ir_cookie Lets clear ireq->ir_cookie in inet_reqsk_alloc() Signed-off-by: Eric Dumazet <edumazet@google.com> Fixes: 33cf7c90fe2f ("net: add real socket cookies") Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6/syncookies.c')
-rw-r--r--net/ipv6/syncookies.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/net/ipv6/syncookies.c b/net/ipv6/syncookies.c
index 7337fc7947e2..66bba6a84e47 100644
--- a/net/ipv6/syncookies.c
+++ b/net/ipv6/syncookies.c
@@ -196,6 +196,7 @@ struct sock *cookie_v6_check(struct sock *sk, struct sk_buff *skb)
ireq = inet_rsk(req);
treq = tcp_rsk(req);
treq->listener = NULL;
+ write_pnet(&ireq->ireq_net, sock_net(sk));
if (security_inet_conn_request(sk, skb, req))
goto out_free;