On 09/12, Oleg Nesterov wrote:
>
> On 09/12, Venu Byravarasu wrote:
> >
> > > --- a/fs/binfmt_elf.c
> > > +++ b/fs/binfmt_elf.c
> > > @@ -1695,30 +1695,19 @@ static int elf_note_info_init(struct elf_note_info
> > > *info)
> > > return 0;
> > > info->psinfo = kmalloc(sizeof(*info->psinfo
On 09/12, Venu Byravarasu wrote:
>
> > --- a/fs/binfmt_elf.c
> > +++ b/fs/binfmt_elf.c
> > @@ -1695,30 +1695,19 @@ static int elf_note_info_init(struct elf_note_info
> > *info)
> > return 0;
> > info->psinfo = kmalloc(sizeof(*info->psinfo), GFP_KERNEL);
>
> Why don't you change kmal
t; Cc: Denys Vlasenko
> Subject: [PATCH] coredump: prevent double-free on an error path in core
> dumper
>
> In !CORE_DUMP_USE_REGSET case, if elf_note_info_init fails to allocate
> memory
> for info->fields, it frees already allocated stuff and returns
> error to its
In !CORE_DUMP_USE_REGSET case, if elf_note_info_init fails to allocate memory
for info->fields, it frees already allocated stuff and returns
error to its caller, fill_note_info. Which in turn returns
error to its caller, elf_core_dump. Which jumps to cleanup
label and calls free_note_info, which wi
4 matches
Mail list logo