Author: tuexen
Date: Thu Dec 16 10:58:45 2010
New Revision: 216481
URL: http://svn.freebsd.org/changeset/base/216481

Log:
  MFC r216397:
  Bugfix: Do correct accounting using the MIB counters when an
          association is aborted via sctp_abort_association().
  
  Approved by: re

Modified:
  stable/8/sys/netinet/sctputil.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)

Modified: stable/8/sys/netinet/sctputil.c
==============================================================================
--- stable/8/sys/netinet/sctputil.c     Thu Dec 16 09:49:16 2010        
(r216480)
+++ stable/8/sys/netinet/sctputil.c     Thu Dec 16 10:58:45 2010        
(r216481)
@@ -3847,6 +3847,11 @@ sctp_abort_association(struct sctp_inpcb
                SCTP_TCB_LOCK(stcb);
                atomic_subtract_int(&stcb->asoc.refcnt, 1);
 #endif
+               SCTP_STAT_INCR_COUNTER32(sctps_aborted);
+               if ((SCTP_GET_STATE(&stcb->asoc) == SCTP_STATE_OPEN) ||
+                   (SCTP_GET_STATE(&stcb->asoc) == 
SCTP_STATE_SHUTDOWN_RECEIVED)) {
+                       SCTP_STAT_DECR_GAUGE32(sctps_currestab);
+               }
                (void)sctp_free_assoc(inp, stcb, SCTP_NORMAL_PROC, 
SCTP_FROM_SCTPUTIL + SCTP_LOC_4);
 #if defined (__APPLE__) || defined(SCTP_SO_LOCK_TESTING)
                SCTP_SOCKET_UNLOCK(so, 1);
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "[email protected]"

Reply via email to