diff options
author | Jeff Garzik <jgarzik@pobox.com> | 2005-09-01 18:02:01 -0400 |
---|---|---|
committer | Jeff Garzik <jgarzik@pobox.com> | 2005-09-01 18:02:01 -0400 |
commit | e3ee3b78f83688a0ae4315e8be71b2eac559904a (patch) | |
tree | deb03bcdd020262af450ed23382d7c921263f5cf /net/ipv4/ip_forward.c | |
parent | 91cb70c1769d9b72dd1efe40c31f01005820b09e (diff) | |
parent | 6b39374a27eb4be7e9d82145ae270ba02ea90dc8 (diff) |
/spare/repo/netdev-2.6 branch 'master'
Diffstat (limited to 'net/ipv4/ip_forward.c')
-rw-r--r-- | net/ipv4/ip_forward.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/net/ipv4/ip_forward.c b/net/ipv4/ip_forward.c index 77094aac6c28..0923add122b4 100644 --- a/net/ipv4/ip_forward.c +++ b/net/ipv4/ip_forward.c | |||
@@ -76,16 +76,12 @@ int ip_forward(struct sk_buff *skb) | |||
76 | * that reaches zero, we must reply an ICMP control message telling | 76 | * that reaches zero, we must reply an ICMP control message telling |
77 | * that the packet's lifetime expired. | 77 | * that the packet's lifetime expired. |
78 | */ | 78 | */ |
79 | 79 | if (skb->nh.iph->ttl <= 1) | |
80 | iph = skb->nh.iph; | ||
81 | |||
82 | if (iph->ttl <= 1) | ||
83 | goto too_many_hops; | 80 | goto too_many_hops; |
84 | 81 | ||
85 | if (!xfrm4_route_forward(skb)) | 82 | if (!xfrm4_route_forward(skb)) |
86 | goto drop; | 83 | goto drop; |
87 | 84 | ||
88 | iph = skb->nh.iph; | ||
89 | rt = (struct rtable*)skb->dst; | 85 | rt = (struct rtable*)skb->dst; |
90 | 86 | ||
91 | if (opt->is_strictroute && rt->rt_dst != rt->rt_gateway) | 87 | if (opt->is_strictroute && rt->rt_dst != rt->rt_gateway) |