Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 22 Jun 2014 16:21:15 +0000 (UTC)
From:      Michael Tuexen <tuexen@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: r267720 - stable/10/sys/netinet
Message-ID:  <201406221621.s5MGLFJa034257@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: tuexen
Date: Sun Jun 22 16:21:14 2014
New Revision: 267720
URL: http://svnweb.freebsd.org/changeset/base/267720

Log:
  MFC r262252:
  
  Remove redundant code and fix a style error.

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

Modified: stable/10/sys/netinet/sctp_input.c
==============================================================================
--- stable/10/sys/netinet/sctp_input.c	Sun Jun 22 15:15:52 2014	(r267719)
+++ stable/10/sys/netinet/sctp_input.c	Sun Jun 22 16:21:14 2014	(r267720)
@@ -439,7 +439,6 @@ sctp_process_init_ack(struct mbuf *m, in
 
 	/* First verify that we have no illegal param's */
 	abort_flag = 0;
-	op_err = NULL;
 
 	op_err = sctp_arethere_unrecognized_parameters(m,
 	    (offset + sizeof(struct sctp_init_chunk)),
@@ -1553,8 +1552,7 @@ sctp_process_cookie_existing(struct mbuf
 			return (NULL);
 
 		}
-		switch SCTP_GET_STATE
-			(asoc) {
+		switch (SCTP_GET_STATE(asoc)) {
 		case SCTP_STATE_COOKIE_WAIT:
 		case SCTP_STATE_COOKIE_ECHOED:
 			/*
@@ -1644,7 +1642,7 @@ sctp_process_cookie_existing(struct mbuf
 			 * have simply lost the COOKIE-ACK
 			 */
 			break;
-			}	/* end switch */
+		}		/* end switch */
 		sctp_stop_all_cookie_timers(stcb);
 		/*
 		 * We ignore the return code here.. not sure if we should

Modified: stable/10/sys/netinet/sctp_output.c
==============================================================================
--- stable/10/sys/netinet/sctp_output.c	Sun Jun 22 15:15:52 2014	(r267719)
+++ stable/10/sys/netinet/sctp_output.c	Sun Jun 22 16:21:14 2014	(r267720)
@@ -3671,7 +3671,6 @@ sctp_add_cookie(struct mbuf *init, int i
 	int sig_offset;
 	uint16_t cookie_sz;
 
-	mret = NULL;
 	mret = sctp_get_mbuf_for_msg((sizeof(struct sctp_state_cookie) +
 	    sizeof(struct sctp_paramhdr)), 0,
 	    M_NOWAIT, 1, MT_DATA);
@@ -8960,7 +8959,6 @@ sctp_send_cookie_ack(struct sctp_tcb *st
 	struct sctp_chunkhdr *hdr;
 	struct sctp_tmit_chunk *chk;
 
-	cookie_ack = NULL;
 	SCTP_TCB_LOCK_ASSERT(stcb);
 
 	cookie_ack = sctp_get_mbuf_for_msg(sizeof(struct sctp_chunkhdr), 0, M_NOWAIT, 1, MT_HEADER);



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