Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 15 Oct 2013 10:11:24 +0000 (UTC)
From:      Gleb Smirnoff <glebius@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r256516 - head/sys/netinet6
Message-ID:  <201310151011.r9FABOvd095146@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: glebius
Date: Tue Oct 15 10:11:23 2013
New Revision: 256516
URL: http://svnweb.freebsd.org/changeset/base/256516

Log:
  Remove useless check of ia6 against NULL, right after dereferencing it.

Modified:
  head/sys/netinet6/ip6_input.c

Modified: head/sys/netinet6/ip6_input.c
==============================================================================
--- head/sys/netinet6/ip6_input.c	Tue Oct 15 10:09:33 2013	(r256515)
+++ head/sys/netinet6/ip6_input.c	Tue Oct 15 10:11:23 2013	(r256516)
@@ -842,7 +842,7 @@ passin:
 			/* Count the packet in the ip address stats */
 			ia6->ia_ifa.if_ipackets++;
 			ia6->ia_ifa.if_ibytes += m->m_pkthdr.len;
-			if (ia6 != NULL && free_ia6 != 0)
+			if (free_ia6)
 				ifa_free(&ia6->ia_ifa);
 			goto hbhcheck;
 		} else {
@@ -854,7 +854,7 @@ passin:
 			    ip6_sprintf(ip6bufs, &ip6->ip6_src),
 			    ip6_sprintf(ip6bufd, &ip6->ip6_dst)));
 
-			if (ia6 != NULL && free_ia6 != 0)
+			if (free_ia6)
 				ifa_free(&ia6->ia_ifa);
 			goto bad;
 		}



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201310151011.r9FABOvd095146>