From owner-svn-src-head@FreeBSD.ORG Sun Oct 9 12:14:10 2011 Return-Path: Delivered-To: svn-src-head@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 160A9106564A; Sun, 9 Oct 2011 12:14:10 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from cell.glebius.int.ru (glebius.int.ru [81.19.64.117]) by mx1.freebsd.org (Postfix) with ESMTP id 5FF1C8FC0A; Sun, 9 Oct 2011 12:14:09 +0000 (UTC) Received: from cell.glebius.int.ru (localhost [127.0.0.1]) by cell.glebius.int.ru (8.14.4/8.14.4) with ESMTP id p99CE7Zm048488; Sun, 9 Oct 2011 16:14:07 +0400 (MSD) (envelope-from glebius@FreeBSD.org) Received: (from glebius@localhost) by cell.glebius.int.ru (8.14.4/8.14.4/Submit) id p99CE7cn048487; Sun, 9 Oct 2011 16:14:07 +0400 (MSD) (envelope-from glebius@FreeBSD.org) X-Authentication-Warning: cell.glebius.int.ru: glebius set sender to glebius@FreeBSD.org using -f Date: Sun, 9 Oct 2011 16:14:07 +0400 From: Gleb Smirnoff To: "Alexander V. Chernikov" Message-ID: <20111009121407.GA94905@FreeBSD.org> References: <201109151228.p8FCSHVY073618@svn.freebsd.org> <20111009063420.GZ94905@FreeBSD.org> <4E918B48.5080408@FreeBSD.org> MIME-Version: 1.0 Content-Type: text/plain; charset=koi8-r Content-Disposition: inline In-Reply-To: <4E918B48.5080408@FreeBSD.org> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: svn-src-head@FreeBSD.org, "Andrey V. Elsukov" , svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r225586 - in head/sys: modules/netgraph/ipfw netgraph X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Oct 2011 12:14:10 -0000 On Sun, Oct 09, 2011 at 03:53:44PM +0400, Alexander V. Chernikov wrote: A> Understood. So can we use more descriptive ENOENT in code below? A> A> tag = m_tag_locate(m, MTAG_IPFW_RULE, 0, NULL); A> if (tag == NULL) { A> NG_FREE_M(m); A> return (EINVAL); /* XXX: find smth better */ A> }; Let you decide that. However, you can first analyze other places in kernel, where m_tag_locate() really should succeed but fails. After that you probably would want to have the same error return value in all these places :) A> Please see an attached patch Patch is ok from my view. -- Totus tuus, Glebius.