Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 4 Sep 2015 09:22:17 +0000 (UTC)
From:      Michael Tuexen <tuexen@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r287456 - head/sys/netinet
Message-ID:  <201509040922.t849MHkw060509@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: tuexen
Date: Fri Sep  4 09:22:16 2015
New Revision: 287456
URL: https://svnweb.freebsd.org/changeset/base/287456

Log:
  Add a NULL pointer check to silence the clang code analyzer.
  
  MFC after:	1 week

Modified:
  head/sys/netinet/sctputil.c

Modified: head/sys/netinet/sctputil.c
==============================================================================
--- head/sys/netinet/sctputil.c	Fri Sep  4 09:19:01 2015	(r287455)
+++ head/sys/netinet/sctputil.c	Fri Sep  4 09:22:16 2015	(r287456)
@@ -2667,6 +2667,9 @@ sctp_notify_assoc_change(uint16_t state,
 
 #endif
 
+	if (stcb == NULL) {
+		return;
+	}
 	if (sctp_stcb_is_feature_on(stcb->sctp_ep, stcb, SCTP_PCB_FLAGS_RECVASSOCEVNT)) {
 		notif_len = sizeof(struct sctp_assoc_change);
 		if (abort != NULL) {



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