From owner-svn-src-all@FreeBSD.ORG Sun Nov 6 20:09:23 2011 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6185A1065673; Sun, 6 Nov 2011 20:09:23 +0000 (UTC) (envelope-from tuexen@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 519778FC14; Sun, 6 Nov 2011 20:09:23 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id pA6K9NrF039586; Sun, 6 Nov 2011 20:09:23 GMT (envelope-from tuexen@svn.freebsd.org) Received: (from tuexen@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id pA6K9NjQ039584; Sun, 6 Nov 2011 20:09:23 GMT (envelope-from tuexen@svn.freebsd.org) Message-Id: <201111062009.pA6K9NjQ039584@svn.freebsd.org> From: Michael Tuexen Date: Sun, 6 Nov 2011 20:09:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r227266 - head/sys/netinet X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 06 Nov 2011 20:09:23 -0000 Author: tuexen Date: Sun Nov 6 20:09:22 2011 New Revision: 227266 URL: http://svn.freebsd.org/changeset/base/227266 Log: Initialize all components of the sent COOKIE. MFC after: 3 days. Modified: head/sys/netinet/sctp_output.c Modified: head/sys/netinet/sctp_output.c ============================================================================== --- head/sys/netinet/sctp_output.c Sun Nov 6 19:57:17 2011 (r227265) +++ head/sys/netinet/sctp_output.c Sun Nov 6 20:09:22 2011 (r227266) @@ -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;