[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1477589786.7065.220.camel@edumazet-glaptop3.roam.corp.google.com>
Date: Thu, 27 Oct 2016 10:36:26 -0700
From: Eric Dumazet <eric.dumazet@...il.com>
To: Lorenzo Colitti <lorenzo@...gle.com>
Cc: netdev@...r.kernel.org, davem@...emloft.net, ek@...gle.com,
zenczykowski@...il.com
Subject: Re: [PATCH net-next 1/3] net: core: Add a UID field to struct sock.
On Fri, 2016-10-28 at 02:20 +0900, Lorenzo Colitti wrote:
> diff --git a/net/core/sock.c b/net/core/sock.c
> index d8e4532e..831e4e8 100644
> --- a/net/core/sock.c
> +++ b/net/core/sock.c
> @@ -1570,6 +1570,7 @@ struct sock *sk_clone_lock(const struct sock *sk, const gfp_t priority)
> */
> sk_refcnt_debug_inc(newsk);
> sk_set_socket(newsk, NULL);
> + newsk->sk_uid = sk->sk_uid;
Not sure why this is needed ?
sk_clone_lock() already copies sk to newsk, using sock_copy(newsk, sk);
> newsk->sk_wq = NULL;
>
> if (newsk->sk_prot->sockets_allocated)
> @@ -2460,8 +2461,11 @@ void sock_init_data(struct socket *sock, struct sock *sk)
Powered by blists - more mailing lists