]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - net/ipv4/inet_connection_sock.c
net: add real socket cookies
[karo-tx-linux.git] / net / ipv4 / inet_connection_sock.c
index 14d02ea905b6bea37240f88054f0cd42db73c4c2..34581f928afa7e83de3bde4e2d20cb80cc896c27 100644 (file)
@@ -678,6 +678,8 @@ struct sock *inet_csk_clone_lock(const struct sock *sk,
                newsk->sk_write_space = sk_stream_write_space;
 
                newsk->sk_mark = inet_rsk(req)->ir_mark;
+               atomic64_set(&newsk->sk_cookie,
+                            atomic64_read(&inet_rsk(req)->ir_cookie));
 
                newicsk->icsk_retransmits = 0;
                newicsk->icsk_backoff     = 0;