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/inet_diag.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/inet_diag.c')
-rw-r--r-- | net/ipv4/inet_diag.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/net/ipv4/inet_diag.c b/net/ipv4/inet_diag.c index 8e7e41b66c79..492858e6faf0 100644 --- a/net/ipv4/inet_diag.c +++ b/net/ipv4/inet_diag.c | |||
@@ -909,11 +909,10 @@ static int __init inet_diag_init(void) | |||
909 | sizeof(struct inet_diag_handler *)); | 909 | sizeof(struct inet_diag_handler *)); |
910 | int err = -ENOMEM; | 910 | int err = -ENOMEM; |
911 | 911 | ||
912 | inet_diag_table = kmalloc(inet_diag_table_size, GFP_KERNEL); | 912 | inet_diag_table = kzalloc(inet_diag_table_size, GFP_KERNEL); |
913 | if (!inet_diag_table) | 913 | if (!inet_diag_table) |
914 | goto out; | 914 | goto out; |
915 | 915 | ||
916 | memset(inet_diag_table, 0, inet_diag_table_size); | ||
917 | idiagnl = netlink_kernel_create(NETLINK_INET_DIAG, 0, inet_diag_rcv, | 916 | idiagnl = netlink_kernel_create(NETLINK_INET_DIAG, 0, inet_diag_rcv, |
918 | THIS_MODULE); | 917 | THIS_MODULE); |
919 | if (idiagnl == NULL) | 918 | if (idiagnl == NULL) |