From owner-svn-src-head@freebsd.org Fri Sep 11 12:56:47 2015 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A34B3A01F5C; Fri, 11 Sep 2015 12:56:47 +0000 (UTC) (envelope-from cy.schubert@komquats.com) Received: from smtp-out-no.shaw.ca (smtp-out-no.shaw.ca [64.59.134.13]) by mx1.freebsd.org (Postfix) with ESMTP id 471A612FC; Fri, 11 Sep 2015 12:56:46 +0000 (UTC) (envelope-from cy.schubert@komquats.com) Received: from cwfw.cwsent.com ([96.50.22.10]) by shaw.ca with SMTP id aNshZZLJqcaY3aNsiZ2lPW; Fri, 11 Sep 2015 06:56:45 -0600 X-Authority-Analysis: v=2.1 cv=CanCnufl c=1 sm=1 tr=0 a=jvE2nwUzI0ECrNeyr98KWA==:117 a=jvE2nwUzI0ECrNeyr98KWA==:17 a=VxmjJ2MpAAAA:8 a=BWvPGDcYAAAA:8 a=kj9zAlcOel0A:10 a=ff-B7xzCdYMA:10 a=6I5d2MoRAAAA:8 a=YxBL1-UpAAAA:8 a=GVM5b0tdj-vQaSZbB0YA:9 a=wLsZ31Jw6K7f5yoZ:21 a=vbYjiWSPCuKEszTw:21 a=CjuIK1q_8ugA:10 Received: from slippy.cwsent.com (slippy [10.1.1.91]) by cwfw.cwsent.com (Postfix) with ESMTP id 4B9B09BF7; Fri, 11 Sep 2015 05:56:43 -0700 (PDT) Received: from slippy (localhost [127.0.0.1]) by slippy.cwsent.com (8.15.2/8.15.2) with ESMTP id t8BBEXDa098190; Fri, 11 Sep 2015 04:14:33 -0700 (PDT) (envelope-from Cy.Schubert@komquats.com) Message-Id: <201509111114.t8BBEXDa098190@slippy.cwsent.com> X-Mailer: exmh version 2.8.0 04/21/2012 with nmh-1.6 Reply-to: Cy Schubert From: Cy Schubert X-os: FreeBSD X-Sender: cy@cwsent.com X-URL: http://www.komquats.com/ To: Alexey Dokuchaev cc: Cy Schubert , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r287653 - head/sys/contrib/ipfilter/netinet In-Reply-To: Message from Alexey Dokuchaev of "Fri, 11 Sep 2015 09:12:22 -0000." <20150911091222.GA61521@FreeBSD.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Fri, 11 Sep 2015 04:14:33 -0700 X-CMAE-Envelope: MS4wfP+ZEvqtK/KzLsVo0prXqqlrSLMObKtiYkUpblzZkgfdQFG2zU/wkmKLlF/sIy7g04YiLBy7D5YZxpz/YcMTEFU2xlidIsIAGTQqiLr8Fb78clhvhKYpgIbGrw6CEjYa+Nl8C5TbJzWJgGrIGWA7ez0GjEKGgo4TgrVAvJTa7Fs6/+UzplpIWiV3L/Mj5VADoWywasJWJnr40wrJ/hauAECMKiXJAuHos492OdWVofIk6wayINI8xaEJNvTPBzOQlm7MTwrii9rNJnRz+R7GuAYc8o814WfuVeARA0DpnUDHJvXyA/5+u1Nj/3LhYfRYNA== X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.20 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: Fri, 11 Sep 2015 12:56:47 -0000 In message <20150911091222.GA61521@FreeBSD.org>, Alexey Dokuchaev writes: > On Fri, Sep 11, 2015 at 08:48:17AM +0000, Cy Schubert wrote: > > New Revision: 287653 > > URL: https://svnweb.freebsd.org/changeset/base/287653 > > > > Log: > > Revert $FreeBSD$. > > > > [...] > > @@ -1,4 +1,4 @@ > > -/* $NetBSD: ip_state.c,v 1.4 2012/12/20 21:42:28 christos Exp $ */ > > +/* $FreeBSD$ */ > > > > /* > > * Copyright (C) 2012 by Darren Reed. > > If this file is part of the contrib sources, don't we usually keep both > ident strings (helps to keep track of future NetBSD revisions, etc.)? But it did have a $FreeBSD$ id at r255332. I inadvertently removed it in r287651. Index: ip_state.c =================================================================== --- ip_state.c (revision 255332) +++ ip_state.c (revision 287651) @@ -1,4 +1,4 @@ -/* $FreeBSD$ */ +/* $NetBSD: ip_state.c,v 1.4 2012/12/20 21:42:28 christos Exp $ */ /* * Copyright (C) 2012 by Darren Reed. @@ -1054,7 +1054,7 @@ /* to pointers and adjusts running stats for the hash table as appropriate. */ /* */ /* This function can fail if the filter rule has had a population policy of */ -/* IP addresses used with stateful filteirng assigned to it. */ +/* IP addresses used with stateful filtering assigned to it. */ /* */ /* Locking: it is assumed that some kind of lock on ipf_state is held. */ /* Exits with is_lock initialised and held - *EVEN IF ERROR*. */ @@ -1081,7 +1081,7 @@ } /* - * If we could trust is_hv, then the modulous would not be needed, + * If we could trust is_hv, then the modulus would not be needed, * but when running with IPFILTER_SYNC, this stops bad values. */ hv = is->is_hv % softs->ipf_state_size; @@ -1672,6 +1672,10 @@ SBUMPD(ipf_state_stats, iss_bucket_full); return 4; } + + /* + * No existing state; create new + */ KMALLOC(is, ipstate_t *); if (is == NULL) { SBUMPD(ipf_state_stats, iss_nomem); @@ -1683,7 +1687,7 @@ is->is_rule = fr; /* - * Do not do the modulous here, it is done in ipf_state_insert(). + * Do not do the modulus here, it is done in ipf_state_insert(). */ if (fr != NULL) { ipftq_t *tq; @@ -1711,7 +1715,7 @@ /* * It may seem strange to set is_ref to 2, but if stsave is not NULL * then a copy of the pointer is being stored somewhere else and in - * the end, it will expect to be able to do osmething with it. + * the end, it will expect to be able to do something with it. */ is->is_me = stsave; if (stsave != NULL) { -- Cheers, Cy Schubert or FreeBSD UNIX: Web: http://www.FreeBSD.org The need of the many outweighs the greed of the few.