diff options
Diffstat (limited to 'fs/exec.c')
-rw-r--r-- | fs/exec.c | 4 |
1 files changed, 1 insertions, 3 deletions
@@ -405,12 +405,10 @@ int setup_arg_pages(struct linux_binprm *bprm, | |||
405 | bprm->loader += stack_base; | 405 | bprm->loader += stack_base; |
406 | bprm->exec += stack_base; | 406 | bprm->exec += stack_base; |
407 | 407 | ||
408 | mpnt = kmem_cache_alloc(vm_area_cachep, GFP_KERNEL); | 408 | mpnt = kmem_cache_zalloc(vm_area_cachep, GFP_KERNEL); |
409 | if (!mpnt) | 409 | if (!mpnt) |
410 | return -ENOMEM; | 410 | return -ENOMEM; |
411 | 411 | ||
412 | memset(mpnt, 0, sizeof(*mpnt)); | ||
413 | |||
414 | down_write(&mm->mmap_sem); | 412 | down_write(&mm->mmap_sem); |
415 | { | 413 | { |
416 | mpnt->vm_mm = mm; | 414 | mpnt->vm_mm = mm; |