diff options
author | Panagiotis Issaris <takis@issaris.org> | 2006-07-21 17:51:30 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2006-07-21 17:51:30 -0400 |
commit | 0da974f4f303a6842516b764507e3c0a03f41e5a (patch) | |
tree | 8872aec792f02040269c6769dd1009b20f71d186 /net/ipv4/arp.c | |
parent | a0ee7c70b22f78593957f99faa06acb4747b8bc0 (diff) |
[NET]: Conversions from kmalloc+memset to k(z|c)alloc.
Signed-off-by: Panagiotis Issaris <takis@issaris.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/arp.c')
-rw-r--r-- | net/ipv4/arp.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/net/ipv4/arp.c b/net/ipv4/arp.c index 7b51b3bdb548..c8a3723bc001 100644 --- a/net/ipv4/arp.c +++ b/net/ipv4/arp.c | |||
@@ -1372,12 +1372,11 @@ static int arp_seq_open(struct inode *inode, struct file *file) | |||
1372 | { | 1372 | { |
1373 | struct seq_file *seq; | 1373 | struct seq_file *seq; |
1374 | int rc = -ENOMEM; | 1374 | int rc = -ENOMEM; |
1375 | struct neigh_seq_state *s = kmalloc(sizeof(*s), GFP_KERNEL); | 1375 | struct neigh_seq_state *s = kzalloc(sizeof(*s), GFP_KERNEL); |
1376 | 1376 | ||
1377 | if (!s) | 1377 | if (!s) |
1378 | goto out; | 1378 | goto out; |
1379 | 1379 | ||
1380 | memset(s, 0, sizeof(*s)); | ||
1381 | rc = seq_open(file, &arp_seq_ops); | 1380 | rc = seq_open(file, &arp_seq_ops); |
1382 | if (rc) | 1381 | if (rc) |
1383 | goto out_kfree; | 1382 | goto out_kfree; |