From owner-svn-src-user@FreeBSD.ORG Mon Nov 25 07:35:02 2013 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 342AB8BC; Mon, 25 Nov 2013 07:35:02 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 2498420C7; Mon, 25 Nov 2013 07:35:02 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id rAP7Z1Jw031475; Mon, 25 Nov 2013 07:35:01 GMT (envelope-from ae@svn.freebsd.org) Received: (from ae@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id rAP7Z1qv031474; Mon, 25 Nov 2013 07:35:01 GMT (envelope-from ae@svn.freebsd.org) Message-Id: <201311250735.rAP7Z1qv031474@svn.freebsd.org> From: "Andrey V. Elsukov" Date: Mon, 25 Nov 2013 07:35:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r258540 - user/ae/inet6/sys/netinet6 X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Nov 2013 07:35:02 -0000 Author: ae Date: Mon Nov 25 07:35:01 2013 New Revision: 258540 URL: http://svnweb.freebsd.org/changeset/base/258540 Log: Initialize sin6_scope_id using mbuf's rcvif. Modified: user/ae/inet6/sys/netinet6/in6_pcb.c Modified: user/ae/inet6/sys/netinet6/in6_pcb.c ============================================================================== --- user/ae/inet6/sys/netinet6/in6_pcb.c Mon Nov 25 06:17:14 2013 (r258539) +++ user/ae/inet6/sys/netinet6/in6_pcb.c Mon Nov 25 07:35:01 2013 (r258540) @@ -1170,8 +1170,8 @@ init_sin6(struct sockaddr_in6 *sin6, str sin6->sin6_len = sizeof(*sin6); sin6->sin6_family = AF_INET6; sin6->sin6_addr = ip->ip6_src; - - (void)sa6_recoverscope(sin6); /* XXX: should catch errors... */ - + if (m->m_pkthdr.rcvif != NULL) + sin6->sin6_scope_id = in6_getscopezone(m->m_pkthdr.rcvif, + in6_addrscope(&sin6->sin6_addr)); return; }