Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 17 Oct 2010 08:46:34 +0000 (UTC)
From:      "Bjoern A. Zeeb" <bz@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org
Subject:   svn commit: r213947 - stable/8/sys/netinet
Message-ID:  <201010170846.o9H8kYRS010919@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bz
Date: Sun Oct 17 08:46:34 2010
New Revision: 213947
URL: http://svn.freebsd.org/changeset/base/213947

Log:
  MFC r213832:
  
    Use ifa_ifwithaddr_check() rather than ifa_ifwithaddr() as we are not
    interested in the result and would leak a reference otherwise.
  
  PR:		kern/151435
  Submitted by:	Andrew Boyer (aboyer averesystems.com)

Modified:
  stable/8/sys/netinet/ip_options.c
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/amd64/include/xen/   (props changed)
  stable/8/sys/cddl/contrib/opensolaris/   (props changed)
  stable/8/sys/contrib/dev/acpica/   (props changed)
  stable/8/sys/contrib/pf/   (props changed)
  stable/8/sys/dev/xen/xenpci/   (props changed)

Modified: stable/8/sys/netinet/ip_options.c
==============================================================================
--- stable/8/sys/netinet/ip_options.c	Sun Oct 17 08:44:34 2010	(r213946)
+++ stable/8/sys/netinet/ip_options.c	Sun Oct 17 08:46:34 2010	(r213947)
@@ -343,7 +343,7 @@ dropit:
 				}
 				(void)memcpy(&ipaddr.sin_addr, sin,
 				    sizeof(struct in_addr));
-				if (ifa_ifwithaddr((SA)&ipaddr) == NULL)
+				if (ifa_ifwithaddr_check((SA)&ipaddr) == 0)
 					continue;
 				cp[IPOPT_OFFSET] += sizeof(struct in_addr);
 				off += sizeof(struct in_addr);



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