[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.LRH.2.00.0907020112520.29793@tundra.namei.org>
Date: Thu, 2 Jul 2009 01:13:38 +1000 (EST)
From: James Morris <jmorris@...ei.org>
To: Amerigo Wang <amwang@...hat.com>,
Linus Torvalds <torvalds@...ux-foundation.org>
cc: linux-kernel@...r.kernel.org,
Alexander Viro <viro@...iv.linux.org.uk>,
Roland McGrath <roland@...hat.com>,
Serge Hallyn <serue@...ibm.com>,
David Howells <dhowells@...hat.com>,
linux-fsdevel@...r.kernel.org,
Andrew Morton <akpm@...ux-foundation.org>
Subject: Re: [Patch 1/3] elf: fix one check-after-use
On Wed, 1 Jul 2009, Amerigo Wang wrote:
>
> Check before use it.
>
> Signed-off-by: WANG Cong <amwang@...hat.com>
> Cc: Alexander Viro <viro@...iv.linux.org.uk>
> Cc: David Howells <dhowells@...hat.com>
Probably needs to go into Linus' tree and stable.
Acked-by: Roland McGrath <roland@...hat.com>
Acked-by: James Morris <jmorris@...ei.org>
>
> ---
> Index: linux-2.6/fs/binfmt_elf.c
> ===================================================================
> --- linux-2.6.orig/fs/binfmt_elf.c
> +++ linux-2.6/fs/binfmt_elf.c
> @@ -1522,11 +1522,11 @@ static int fill_note_info(struct elfhdr
> info->thread = NULL;
>
> psinfo = kmalloc(sizeof(*psinfo), GFP_KERNEL);
> - fill_note(&info->psinfo, "CORE", NT_PRPSINFO, sizeof(*psinfo), psinfo);
> -
> if (psinfo == NULL)
> return 0;
>
> + fill_note(&info->psinfo, "CORE", NT_PRPSINFO, sizeof(*psinfo), psinfo);
> +
> /*
> * Figure out how many notes we're going to need for each thread.
> */
>
--
James Morris
<jmorris@...ei.org>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists