Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 15 Oct 2012 07:57:55 +0000 (UTC)
From:      Gleb Smirnoff <glebius@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r241575 - head/sys/netinet
Message-ID:  <201210150757.q9F7vtQg043851@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: glebius
Date: Mon Oct 15 07:57:55 2012
New Revision: 241575
URL: http://svn.freebsd.org/changeset/base/241575

Log:
  We don't need to convert ip6_len to host byte order before
  ip6_output(), the IPv6 stack is working in net byte order.
  
  The reason this code worked before is that ip6_output()
  doesn't look at ip6_plen at all and recalculates it based
  on mbuf length.

Modified:
  head/sys/netinet/ip_divert.c

Modified: head/sys/netinet/ip_divert.c
==============================================================================
--- head/sys/netinet/ip_divert.c	Mon Oct 15 06:48:50 2012	(r241574)
+++ head/sys/netinet/ip_divert.c	Mon Oct 15 07:57:55 2012	(r241575)
@@ -402,8 +402,6 @@ div_output(struct socket *so, struct mbu
 				INP_RUNLOCK(inp);
 				goto cantsend;
 			}
-
-			ip6->ip6_plen = ntohs(ip6->ip6_plen);
 			break;
 		    }
 #endif



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