Skip to content

Commit

Permalink
[NETFILTER]: ip6t_HL: remove write-only variable
Browse files Browse the repository at this point in the history
Noticed by Alexey Dobriyan <adobriyan@gmail.com>

Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Patrick McHardy authored and David S. Miller committed Sep 22, 2006
1 parent ca39df6 commit 7cf7393
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions net/ipv6/netfilter/ip6t_HL.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ static unsigned int ip6t_hl_target(struct sk_buff **pskb,
{
struct ipv6hdr *ip6h;
const struct ip6t_HL_info *info = targinfo;
u_int16_t diffs[2];
int new_hl;

if (!skb_make_writable(pskb, (*pskb)->len))
Expand All @@ -53,11 +52,8 @@ static unsigned int ip6t_hl_target(struct sk_buff **pskb,
break;
}

if (new_hl != ip6h->hop_limit) {
diffs[0] = htons(((unsigned)ip6h->hop_limit) << 8) ^ 0xFFFF;
if (new_hl != ip6h->hop_limit)
ip6h->hop_limit = new_hl;
diffs[1] = htons(((unsigned)ip6h->hop_limit) << 8);
}

return IP6T_CONTINUE;
}
Expand Down

0 comments on commit 7cf7393

Please sign in to comment.