Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 27 Jul 2016 06:31:40 +0000 (UTC)
From:      Julien Charbon <jch@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject:   svn commit: r303365 - stable/10/sys/netinet
Message-ID:  <201607270631.u6R6Venc070851@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jch
Date: Wed Jul 27 06:31:40 2016
New Revision: 303365
URL: https://svnweb.freebsd.org/changeset/base/303365

Log:
  MFC r273014:
  
  A connection in TIME_WAIT state before calling close() actually did not
  received any RST packet.  Do not set error to ECONNRESET in this case.
  
  Differential Revision:	https://reviews.freebsd.org/D879
  Reviewed by:		rpaulo, adrian
  Approved by:		jhb (mentor)
  Sponsored by:		Verisign, Inc.

Modified:
  stable/10/sys/netinet/tcp_usrreq.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/netinet/tcp_usrreq.c
==============================================================================
--- stable/10/sys/netinet/tcp_usrreq.c	Wed Jul 27 06:29:41 2016	(r303364)
+++ stable/10/sys/netinet/tcp_usrreq.c	Wed Jul 27 06:31:40 2016	(r303365)
@@ -625,7 +625,9 @@ tcp_usr_disconnect(struct socket *so)
 	inp = sotoinpcb(so);
 	KASSERT(inp != NULL, ("tcp_usr_disconnect: inp == NULL"));
 	INP_WLOCK(inp);
-	if (inp->inp_flags & (INP_TIMEWAIT | INP_DROPPED)) {
+	if (inp->inp_flags & INP_TIMEWAIT)
+		goto out;
+	if (inp->inp_flags & INP_DROPPED) {
 		error = ECONNRESET;
 		goto out;
 	}



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