From owner-svn-src-head@freebsd.org Wed Apr 19 23:06:09 2017 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 1ACE1D46D88; Wed, 19 Apr 2017 23:06:09 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E11C8884; Wed, 19 Apr 2017 23:06:08 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v3JN68WW052326; Wed, 19 Apr 2017 23:06:08 GMT (envelope-from np@FreeBSD.org) Received: (from np@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v3JN68Cu052325; Wed, 19 Apr 2017 23:06:08 GMT (envelope-from np@FreeBSD.org) Message-Id: <201704192306.v3JN68Cu052325@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: np set sender to np@FreeBSD.org using -f From: Navdeep Parhar Date: Wed, 19 Apr 2017 23:06:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r317177 - head/sys/netinet X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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: Wed, 19 Apr 2017 23:06:09 -0000 Author: np Date: Wed Apr 19 23:06:07 2017 New Revision: 317177 URL: https://svnweb.freebsd.org/changeset/base/317177 Log: Free lro_hash unconditionally, just like lro_mbuf_data a few lines later. Fix whitespace nit while here. Modified: head/sys/netinet/tcp_lro.c Modified: head/sys/netinet/tcp_lro.c ============================================================================== --- head/sys/netinet/tcp_lro.c Wed Apr 19 22:50:19 2017 (r317176) +++ head/sys/netinet/tcp_lro.c Wed Apr 19 23:06:07 2017 (r317177) @@ -175,17 +175,15 @@ tcp_lro_free(struct lro_ctrl *lc) } /* free hash table */ - if (lc->lro_hash != NULL) { - free(lc->lro_hash, M_LRO); - lc->lro_hash = NULL; - } + free(lc->lro_hash, M_LRO); + lc->lro_hash = NULL; lc->lro_hashsz = 0; /* free mbuf array, if any */ for (x = 0; x != lc->lro_mbuf_count; x++) m_freem(lc->lro_mbuf_data[x].mb); lc->lro_mbuf_count = 0; - + /* free allocated memory, if any */ free(lc->lro_mbuf_data, M_LRO); lc->lro_mbuf_data = NULL;