Author: tuexen
Date: Sun Feb  5 18:21:03 2012
New Revision: 231029
URL: http://svn.freebsd.org/changeset/base/231029

Log:
  MFC r228391:
   Fix a bug reported by Irene Ruengeler which resulted in not sending
   out HEARTBEATs when requested by the user. The HEARTBEATs were only
   queued, but not actually sent out.

Modified:
  stable/9/sys/netinet/sctp_constants.h
  stable/9/sys/netinet/sctp_usrreq.c
Directory Properties:
  stable/9/sys/   (props changed)

Modified: stable/9/sys/netinet/sctp_constants.h
==============================================================================
--- stable/9/sys/netinet/sctp_constants.h       Sun Feb  5 18:16:38 2012        
(r231028)
+++ stable/9/sys/netinet/sctp_constants.h       Sun Feb  5 18:21:03 2012        
(r231029)
@@ -391,6 +391,8 @@ __FBSDID("$FreeBSD$");
 #define SCTP_OUTPUT_FROM_COOKIE_ACK     14
 #define SCTP_OUTPUT_FROM_DRAIN          15
 #define SCTP_OUTPUT_FROM_CLOSING        16
+#define SCTP_OUTPUT_FROM_SOCKOPT        17
+
 /* SCTP chunk types are moved sctp.h for application (NAT, FW) use */
 
 /* align to 32-bit sizes */

Modified: stable/9/sys/netinet/sctp_usrreq.c
==============================================================================
--- stable/9/sys/netinet/sctp_usrreq.c  Sun Feb  5 18:16:38 2012        
(r231028)
+++ stable/9/sys/netinet/sctp_usrreq.c  Sun Feb  5 18:21:03 2012        
(r231029)
@@ -4642,6 +4642,7 @@ sctp_setopt(struct socket *so, int optna
                                        if (paddrp->spp_flags & SPP_HB_DEMAND) {
                                                /* on demand HB */
                                                sctp_send_hb(stcb, net, 
SCTP_SO_LOCKED);
+                                               sctp_chunk_output(inp, stcb, 
SCTP_OUTPUT_FROM_SOCKOPT, SCTP_SO_LOCKED);
                                                
sctp_timer_start(SCTP_TIMER_TYPE_HEARTBEAT, inp, stcb, net);
                                        }
                                        if ((paddrp->spp_flags & 
SPP_PMTUD_DISABLE) && (paddrp->spp_pathmtu >= SCTP_SMALLEST_PMTU)) {
_______________________________________________
svn-src-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to