summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--net/sched/act_nat.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/net/sched/act_nat.c b/net/sched/act_nat.c
index 724553e8ed7b..ea008f57fc83 100644
--- a/net/sched/act_nat.c
+++ b/net/sched/act_nat.c
@@ -218,6 +218,7 @@ static int tcf_nat(struct sk_buff *skb, struct tc_action *a,
 		if (!pskb_may_pull(skb, ihl + sizeof(*icmph) + sizeof(*iph)))
 			goto drop;
 
+		icmph = (void *)(skb_network_header(skb) + ihl);
 		iph = (void *)(icmph + 1);
 		if (egress)
 			addr = iph->daddr;