aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorLi Zefan <lizf@cn.fujitsu.com>2007-11-13 05:57:16 -0500
committerDavid S. Miller <davem@davemloft.net>2007-11-13 05:57:16 -0500
commite0bf9cf15fc30d300b7fbd821c6bc975531fab44 (patch)
tree724d96429ab6aabe435b354ca282a9c5812b986c /net
parentd71209ded2ba6010070d02005384897c59859d00 (diff)
[NETFILTER]: nf_nat: fix memset error
The size passing to memset is the size of a pointer. Signed-off-by: Li Zefan <lizf@cn.fujitsu.com> Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r--net/ipv4/netfilter/nf_nat_core.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv4/netfilter/nf_nat_core.c b/net/ipv4/netfilter/nf_nat_core.c
index 56e93f692e82..70e7997ea284 100644
--- a/net/ipv4/netfilter/nf_nat_core.c
+++ b/net/ipv4/netfilter/nf_nat_core.c
@@ -681,7 +681,7 @@ static int clean_nat(struct nf_conn *i, void *data)
681 681
682 if (!nat) 682 if (!nat)
683 return 0; 683 return 0;
684 memset(nat, 0, sizeof(nat)); 684 memset(nat, 0, sizeof(*nat));
685 i->status &= ~(IPS_NAT_MASK | IPS_NAT_DONE_MASK | IPS_SEQ_ADJUST); 685 i->status &= ~(IPS_NAT_MASK | IPS_NAT_DONE_MASK | IPS_SEQ_ADJUST);
686 return 0; 686 return 0;
687} 687}