From mboxrd@z Thu Jan 1 00:00:00 1970 From: ebiederm-aS9lmoZGLiVWk0Htik3J/w@public.gmane.org (Eric W. Biederman) Subject: Re: [PATCH] pid: Extend/Fix pid_vnr Date: Fri, 07 Dec 2007 11:10:09 -0700 Message-ID: References: <20071206171513.GB10674@tv-sign.ru> <20071207010424.GB29065@us.ibm.com> <20071207015727.GB32659@sergelap.austin.ibm.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: In-Reply-To: <20071207015727.GB32659-6s5zFf/epYLPQpwDFJZrxKsjOiXwFzmk@public.gmane.org> (Serge E. Hallyn's message of "Thu, 6 Dec 2007 19:57:27 -0600") List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: containers-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org Errors-To: containers-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org To: "Serge E. Hallyn" Cc: Linux Containers , Andrew Morton , Oleg Nesterov , Pavel Emelyanov List-Id: containers.vger.kernel.org "Serge E. Hallyn" writes: > Quoting sukadev-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org (sukadev-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org): >> Oleg Nesterov [oleg-6lXkIZvqkOAvJsYlp49lxw@public.gmane.org] wrote: >> | On 12/05, Eric W. Biederman wrote: >> | > >> | > +pid_t pid_vnr(struct pid *pid) >> | > +{ >> | > + return pid_nr_ns(pid, current->nsproxy->pid_ns); >> | > +} >> >> Hmm. current->nsproxy be NULL during process exit ? >> So this safe as long as pid_vnr() is not called after a >> process exits its namespaces. Probably no such callers atm. > > Yes I did a little audit for those this morning bc I frankly didn't > believe there weren't any. But I couldn't find any :) Cool. The only case pid_vnr would make sense in that context is if we were talking to user space after we had exited our namespaces. Which is at least as stretch. Eric