netfilter: xtables: compat out of scope fix
authorAlexey Dobriyan <adobriyan@gmail.com>
Mon, 8 Feb 2010 19:17:43 +0000 (11:17 -0800)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 23 Feb 2010 15:37:53 +0000 (07:37 -0800)
commitd619798aab2394997e0a4b9d2cb362306f221c97
treef5c654d2c52574b56625f0c23848faff9911e717
parent51d3a347944f76bc2f304e0622d61b9b39fec585
netfilter: xtables: compat out of scope fix

commit 14c7dbe043d01a83a30633ab6b109ba2ac61d9f7 upstream.

As per C99 6.2.4(2) when temporary table data goes out of scope,
the behaviour is undefined:

if (compat) {
struct foo tmp;
...
private = &tmp;
}
[dereference private]

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
net/ipv4/netfilter/arp_tables.c
net/ipv4/netfilter/ip_tables.c
net/ipv6/netfilter/ip6_tables.c