svn commit: r231475 - stable/8/sys/netinet
Michael Tuexen
tuexen at FreeBSD.org
Fri Feb 10 23:32:04 UTC 2012
Author: tuexen
Date: Fri Feb 10 23:32:04 2012
New Revision: 231475
URL: http://svn.freebsd.org/changeset/base/231475
Log:
MFC r227266:
Initialize all components of the sent COOKIE.
Modified:
stable/8/sys/netinet/sctp_output.c
Directory Properties:
stable/8/sys/ (props changed)
stable/8/sys/amd64/include/xen/ (props changed)
stable/8/sys/boot/ (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)
stable/8/sys/dev/e1000/ (props changed)
Modified: stable/8/sys/netinet/sctp_output.c
==============================================================================
--- stable/8/sys/netinet/sctp_output.c Fri Feb 10 23:30:29 2012 (r231474)
+++ stable/8/sys/netinet/sctp_output.c Fri Feb 10 23:32:04 2012 (r231475)
@@ -5711,6 +5711,8 @@ do_a_abort:
stc.laddress[2] = 0;
stc.laddress[3] = 0;
stc.laddr_type = SCTP_IPV4_ADDRESS;
+ /* scope_id is only for v6 */
+ stc.scope_id = 0;
break;
#endif
#ifdef INET6
@@ -5719,6 +5721,7 @@ do_a_abort:
memcpy(&stc.address, &sin6->sin6_addr,
sizeof(struct in6_addr));
stc.addr_type = SCTP_IPV6_ADDRESS;
+ stc.scope_id = sin6->sin6_scope_id;
if (net->src_addr_selected == 0) {
/*
* strange case here, the INIT should have
@@ -5746,6 +5749,7 @@ do_a_abort:
/* who are we */
memcpy(stc.identification, SCTP_VERSION_STRING,
min(strlen(SCTP_VERSION_STRING), sizeof(stc.identification)));
+ memset(stc.reserved, 0, SCTP_RESERVE_SPACE);
/* now the chunk header */
initack->ch.chunk_type = SCTP_INITIATION_ACK;
initack->ch.chunk_flags = 0;
More information about the svn-src-all
mailing list