From 9969ace850a406866e8bc9ad22568e041181816c Mon Sep 17 00:00:00 2001 From: Alan Cox Date: Mon, 17 Dec 2012 16:02:09 -0800 Subject: [PATCH] --- yaml --- r: 346426 b: refs/heads/master c: 6899e92d65c490c5292752718ff277b123f8c00a h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/fs/binfmt_elf.c | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index d2ac23e22538..d851d5eda4e8 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 323c1260ba2c4b5c4b2a1e9ab6657cde54ccf554 +refs/heads/master: 6899e92d65c490c5292752718ff277b123f8c00a diff --git a/trunk/fs/binfmt_elf.c b/trunk/fs/binfmt_elf.c index 6d7d1647a68c..0c42cdbabecf 100644 --- a/trunk/fs/binfmt_elf.c +++ b/trunk/fs/binfmt_elf.c @@ -1601,8 +1601,10 @@ static int fill_note_info(struct elfhdr *elf, int phdrs, info->thread = NULL; psinfo = kmalloc(sizeof(*psinfo), GFP_KERNEL); - if (psinfo == NULL) + if (psinfo == NULL) { + info->psinfo.data = NULL; /* So we don't free this wrongly */ return 0; + } fill_note(&info->psinfo, "CORE", NT_PRPSINFO, sizeof(*psinfo), psinfo);