diff options
author | Jesper Juhl <jj@chaosbits.net> | 2010-10-30 18:37:16 +0200 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2010-12-16 19:10:54 +0100 |
commit | 863abad4f644b6c12bc8176206b35fa7e7cfe1a9 (patch) | |
tree | cf6aacba2461f8d59b81bb03ca345f0d2270db39 /arch/mips/loongson/common | |
parent | MIPS: compat: Don't clobber personality bits in 32-bit sys_personality(). (diff) | |
download | linux-863abad4f644b6c12bc8176206b35fa7e7cfe1a9.tar.xz linux-863abad4f644b6c12bc8176206b35fa7e7cfe1a9.zip |
MIPS: VPE loader: Check vmalloc return value in vpe_open
The return value of the vmalloc() call in arch/mips/kernel/vpe.c::vpe_open()
is not checked, so we potentially store a null pointer in v->pbuffer. Add
a check for a null return and then return -ENOMEM in that case.
[Ralf: The check added by Jesper's original patch is where it logically
should be. Adding it eleminated the need for the checks in a few other
places, so I removed them. There still is a zillion of other things that
need to be fixed in this file / API.]
Signed-off-by: Jesper Juhl <jj@chaosbits.net>
Cc: linux-mips@linux-mips.org
Cc: linux-kernel@vger.kernel.org
Patchwork: https://patchwork.linux-mips.org/patch/1747/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/loongson/common')
0 files changed, 0 insertions, 0 deletions