svn commit: r227424 - stable/9/sys/netinet
Michael Tuexen
tuexen at FreeBSD.org
Thu Nov 10 19:36:20 UTC 2011
Author: tuexen
Date: Thu Nov 10 19:36:19 2011
New Revision: 227424
URL: http://svn.freebsd.org/changeset/base/227424
Log:
MFC 227266:
Initialize all components of the sent COOKIE.
Approved by: re@
Modified:
stable/9/sys/netinet/sctp_output.c
Directory Properties:
stable/9/sys/ (props changed)
stable/9/sys/amd64/include/xen/ (props changed)
stable/9/sys/boot/ (props changed)
stable/9/sys/boot/i386/efi/ (props changed)
stable/9/sys/boot/ia64/efi/ (props changed)
stable/9/sys/boot/ia64/ski/ (props changed)
stable/9/sys/boot/powerpc/boot1.chrp/ (props changed)
stable/9/sys/boot/powerpc/ofw/ (props changed)
stable/9/sys/cddl/contrib/opensolaris/ (props changed)
stable/9/sys/conf/ (props changed)
stable/9/sys/contrib/dev/acpica/ (props changed)
stable/9/sys/contrib/octeon-sdk/ (props changed)
stable/9/sys/contrib/pf/ (props changed)
stable/9/sys/contrib/x86emu/ (props changed)
Modified: stable/9/sys/netinet/sctp_output.c
==============================================================================
--- stable/9/sys/netinet/sctp_output.c Thu Nov 10 19:10:53 2011 (r227423)
+++ stable/9/sys/netinet/sctp_output.c Thu Nov 10 19:36:19 2011 (r227424)
@@ -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-stable-9
mailing list