Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 8 Jun 2017 06:37:11 +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: r319687 - head/sys/netinet
Message-ID:  <201706080637.v586bBdD028493@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: glebius
Date: Thu Jun  8 06:37:11 2017
New Revision: 319687
URL: https://svnweb.freebsd.org/changeset/base/319687

Log:
  This code was missing socket unlock and socket buffer lock, but it
  worked since right now these two locks are the same.

Modified:
  head/sys/netinet/sctputil.c

Modified: head/sys/netinet/sctputil.c
==============================================================================
--- head/sys/netinet/sctputil.c	Thu Jun  8 06:34:09 2017	(r319686)
+++ head/sys/netinet/sctputil.c	Thu Jun  8 06:37:11 2017	(r319687)
@@ -2792,6 +2792,7 @@ set_error:
 				stcb->sctp_socket->so_error = ECONNABORTED;
 			}
 		}
+		SOCK_UNLOCK(stcb->sctp_socket);
 	}
 	/* Wake ANY sleepers */
 #if defined(__APPLE__) || defined(SCTP_SO_LOCK_TESTING)
@@ -2811,7 +2812,7 @@ set_error:
 	if (((stcb->sctp_ep->sctp_flags & SCTP_PCB_FLAGS_TCPTYPE) ||
 	    (stcb->sctp_ep->sctp_flags & SCTP_PCB_FLAGS_IN_TCPPOOL)) &&
 	    ((state == SCTP_COMM_LOST) || (state == SCTP_CANT_STR_ASSOC))) {
-		socantrcvmore_locked(stcb->sctp_socket);
+		socantrcvmore(stcb->sctp_socket);
 	}
 	sorwakeup(stcb->sctp_socket);
 	sowwakeup(stcb->sctp_socket);



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