From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tejun Heo Subject: Re: [PATCH 5/5] cgroup: separate out cgroup_attach_proc error handling code Date: Tue, 20 Dec 2011 16:13:47 -0800 Message-ID: <20111221001347.GQ10752@google.com> References: <1324422873-31001-1-git-send-email-msb@chromium.org> <1324422873-31001-6-git-send-email-msb@chromium.org> <20111220233502.GN10752@google.com> <20111221000231.GX13529@google.com> Mime-Version: 1.0 Return-path: DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; bh=BemFeTl3KaOWZ4aSMyKCwAXZHY707E/dGLh8YjWBDPg=; b=BwsmOdyTa3q+ut1oKbM41ZbP3wD20bTEunoakyyVWlQ55zHBt/kC6rVwNTHlJ0IJ8k B6s8zGZhxHPyXMeVflgNjTl/XuY93y/lyP9vvRe8Sxb/wQ7oP36aRNclGk/SlWayg5vm asgnX7R6IdZnTcM1CvV3YdCoQxjGnnTkRnjm0= Content-Disposition: inline In-Reply-To: <20111221000231.GX13529-hpIqsD4AKlfQT0dZR+AlfA@public.gmane.org> Sender: cgroups-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org List-ID: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Mandeep Singh Baines Cc: Li Zefan , LKML , Frederic Weisbecker , containers-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org, cgroups-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, KAMEZAWA Hiroyuki , Oleg Nesterov , Andrew Morton , Paul Menage On Tue, Dec 20, 2011 at 04:02:31PM -0800, Mandeep Singh Baines wrote: > > Hmm... maybe goto out_free_group_list? Duplicating cleanup on success > > and failure paths can lead future updaters forget one of them. The > > exit path in this function isn't pretty but I don't think the proposed > > patch improves it either. > > > > Should I drop the patch or add the goto? Its 5/5 so easy enough to drop > since nothing else depends on it. Yeah, let's drop it for now. Thanks. -- tejun From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753631Ab1LUAN7 (ORCPT ); Tue, 20 Dec 2011 19:13:59 -0500 Received: from mail-gx0-f174.google.com ([209.85.161.174]:47311 "EHLO mail-gx0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753539Ab1LUANx (ORCPT ); Tue, 20 Dec 2011 19:13:53 -0500 Date: Tue, 20 Dec 2011 16:13:47 -0800 From: Tejun Heo To: Mandeep Singh Baines Cc: Li Zefan , LKML , Frederic Weisbecker , containers@lists.linux-foundation.org, cgroups@vger.kernel.org, KAMEZAWA Hiroyuki , Oleg Nesterov , Andrew Morton , Paul Menage Subject: Re: [PATCH 5/5] cgroup: separate out cgroup_attach_proc error handling code Message-ID: <20111221001347.GQ10752@google.com> References: <1324422873-31001-1-git-send-email-msb@chromium.org> <1324422873-31001-6-git-send-email-msb@chromium.org> <20111220233502.GN10752@google.com> <20111221000231.GX13529@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20111221000231.GX13529@google.com> User-Agent: Mutt/1.5.20 (2009-06-14) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Dec 20, 2011 at 04:02:31PM -0800, Mandeep Singh Baines wrote: > > Hmm... maybe goto out_free_group_list? Duplicating cleanup on success > > and failure paths can lead future updaters forget one of them. The > > exit path in this function isn't pretty but I don't think the proposed > > patch improves it either. > > > > Should I drop the patch or add the goto? Its 5/5 so easy enough to drop > since nothing else depends on it. Yeah, let's drop it for now. Thanks. -- tejun