Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 2 Jun 2011 10:21:05 +0000 (UTC)
From:      Robert Watson <rwatson@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r222602 - head/sys/netinet
Message-ID:  <201106021021.p52AL5bM011709@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: rwatson
Date: Thu Jun  2 10:21:05 2011
New Revision: 222602
URL: http://svn.freebsd.org/changeset/base/222602

Log:
  Do not leak the pcbinfohash lock in the case where in6_pcbladdr() returns
  an error during TCP connect(2) on an IPv6 socket.
  
  Submitted by:	bz
  Sponsored by:	Juniper Networks, Inc.

Modified:
  head/sys/netinet/tcp_usrreq.c

Modified: head/sys/netinet/tcp_usrreq.c
==============================================================================
--- head/sys/netinet/tcp_usrreq.c	Thu Jun  2 10:18:49 2011	(r222601)
+++ head/sys/netinet/tcp_usrreq.c	Thu Jun  2 10:21:05 2011	(r222602)
@@ -1158,7 +1158,7 @@ tcp6_connect(struct tcpcb *tp, struct so
 	 */
 	error = in6_pcbladdr(inp, nam, &addr6);
 	if (error)
-		return error;
+		goto out;
 	oinp = in6_pcblookup_hash_locked(inp->inp_pcbinfo,
 				  &sin6->sin6_addr, sin6->sin6_port,
 				  IN6_IS_ADDR_UNSPECIFIED(&inp->in6p_laddr)



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