[PATCH] fs: Conversions from kmalloc+memset to k(z|c)alloc
Conversions from kmalloc+memset to kzalloc. Signed-off-by: Panagiotis Issaris <takis@issaris.org> Jffs2-bit-acked-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:

committed by
Linus Torvalds

parent
32c2d2bc4b
commit
f8314dc60c
@@ -100,11 +100,10 @@ nlm_lookup_file(struct svc_rqst *rqstp, struct nlm_file **result,
|
||||
nlm_debug_print_fh("creating file for", f);
|
||||
|
||||
nfserr = nlm_lck_denied_nolocks;
|
||||
file = (struct nlm_file *) kmalloc(sizeof(*file), GFP_KERNEL);
|
||||
file = kzalloc(sizeof(*file), GFP_KERNEL);
|
||||
if (!file)
|
||||
goto out_unlock;
|
||||
|
||||
memset(file, 0, sizeof(*file));
|
||||
memcpy(&file->f_handle, f, sizeof(struct nfs_fh));
|
||||
file->f_hash = hash;
|
||||
init_MUTEX(&file->f_sema);
|
||||
|
Reference in New Issue
Block a user