Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 289782
b: refs/heads/master
c: c45a3df
h: refs/heads/master
v: v3
  • Loading branch information
David S. Miller committed Jan 28, 2012
1 parent 9a77a92 commit 7e35d71
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 4991969a1027826c3db19dd3e600e145603e6928
refs/heads/master: c45a3dfb59c0f17bdbd294dd01efb2d7f99a32c7
8 changes: 3 additions & 5 deletions trunk/net/ipv6/ip6_output.c
Original file line number Diff line number Diff line change
Expand Up @@ -388,7 +388,6 @@ int ip6_forward(struct sk_buff *skb)
struct ipv6hdr *hdr = ipv6_hdr(skb);
struct inet6_skb_parm *opt = IP6CB(skb);
struct net *net = dev_net(dst->dev);
struct neighbour *n;
u32 mtu;

if (net->ipv6.devconf_all->forwarding == 0)
Expand Down Expand Up @@ -463,8 +462,7 @@ int ip6_forward(struct sk_buff *skb)
send redirects to source routed frames.
We don't send redirects to frames decapsulated from IPsec.
*/
n = dst_get_neighbour_noref(dst);
if (skb->dev == dst->dev && n && opt->srcrt == 0 && !skb_sec_path(skb)) {
if (skb->dev == dst->dev && opt->srcrt == 0 && !skb_sec_path(skb)) {
struct in6_addr *target = NULL;
struct rt6_info *rt;

Expand All @@ -474,8 +472,8 @@ int ip6_forward(struct sk_buff *skb)
*/

rt = (struct rt6_info *) dst;
if ((rt->rt6i_flags & RTF_GATEWAY))
target = (struct in6_addr*)&n->primary_key;
if (rt->rt6i_flags & RTF_GATEWAY)
target = &rt->rt6i_gateway;
else
target = &hdr->daddr;

Expand Down

0 comments on commit 7e35d71

Please sign in to comment.