• Andrew Morton's avatar
    [PATCH] fix memory leak in load_elf_binary() · 3ed88a51
    Andrew Morton authored
    - Fix an error-path leak of memory and a dentry in load_elf_binary()
      (spotted by Oleg Drokin).
    
    - Tidy up the handling of bad executable images: return -ENOEXEC rather
      than 0.  (We've committed suicide anyway, so probably nobody gets to see
      this).
    
    - Fix up the logic in load_aout_interp().  It gets itself all set up to
      return -ENOEXEC but there is in fact no path by which it can do this.  Just
      return ~0UL on errors, like load_elf_interp().
    3ed88a51
binfmt_elf.c 37.9 KB