Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756559Ab2JIRtH (ORCPT ); Tue, 9 Oct 2012 13:49:07 -0400 Received: from mx1.redhat.com ([209.132.183.28]:26927 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752195Ab2JIRtF (ORCPT ); Tue, 9 Oct 2012 13:49:05 -0400 Date: Tue, 9 Oct 2012 19:50:11 +0200 From: Oleg Nesterov To: Andrey Wagin Cc: linux-kernel@vger.kernel.org, Andrew Morton , Serge Hallyn , Paul Gortmaker , "Eric W. Biederman" , Vasiliy Kulikov , Cyrill Gorcunov , Pavel Emelyanov Subject: Re: [PATCH] [RFC] pidns: don't zap processes several times Message-ID: <20121009175011.GA10492@redhat.com> References: <1349603358-1085282-1-git-send-email-avagin@openvz.org> <20121007190118.GA16068@redhat.com> <20121009162925.GA6517@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.18 (2008-05-17) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 790 Lines: 25 On 10/09, Andrey Wagin wrote: > > 2012/10/9 Oleg Nesterov : > > Hmm. This is off-topic, but... > > > > create_pid_namespace: > > > > unsigned int level = parent_pid_ns->level + 1; > > ns->pid_cachep = create_pid_cachep(level + 1); > > Yes, it's correct, because pid->numbers[ns->level] should be valid, so > a size of an array pid->numbers should be (level + 1). Ah, yes. I missed that ns->level is "last index", not "array size". Indeed, init_pid_ns.level = 0. Thanks Andrey. Oleg. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/