]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
act_nat: the checksum of ICMP doesn't have pseudo header
authorChangli Gao <xiaosuo@gmail.com>
Thu, 29 Jul 2010 14:04:18 +0000 (14:04 +0000)
committerGreg Kroah-Hartman <gregkh@suse.de>
Thu, 26 Aug 2010 23:41:52 +0000 (16:41 -0700)
[ Upstream commit 3a3dfb062c2e086c202d34f09ce29634515ad256 ]

after updating the value of the ICMP payload, inet_proto_csum_replace4() should
be called with zero pseudohdr.

Signed-off-by: Changli Gao <xiaosuo@gmail.com>
Acked-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
net/sched/act_nat.c

index d885ba311564d9a766fce6eac37edbaf0ed82b71..37e198cda945d5014ed809dc7cb431bfe8e198e8 100644 (file)
@@ -240,7 +240,7 @@ static int tcf_nat(struct sk_buff *skb, struct tc_action *a,
                        iph->saddr = new_addr;
 
                inet_proto_csum_replace4(&icmph->checksum, skb, addr, new_addr,
-                                        1);
+                                        0);
                break;
        }
        default: