[PATCH] kernel core: replace kmalloc+memset with kzalloc

Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
Burman Yan
2006-12-06 20:38:51 -08:00
committed by Linus Torvalds
parent 304e61e6fb
commit 4668edc334
6 changed files with 7 additions and 14 deletions
+1 -2
View File
@@ -636,10 +636,9 @@ static struct audit_rule *audit_krule_to_rule(struct audit_krule *krule)
struct audit_rule *rule;
int i;
rule = kmalloc(sizeof(*rule), GFP_KERNEL);
rule = kzalloc(sizeof(*rule), GFP_KERNEL);
if (unlikely(!rule))
return NULL;
memset(rule, 0, sizeof(*rule));
rule->flags = krule->flags | krule->listnr;
rule->action = krule->action;