Prevent NULL dereference if kmalloc() fails. Signed-off-by: Roel Kluin <roel.kluin@xxxxxxxxx> --- Found with sed: http://kernelnewbies.org/roelkluin diff --git a/arch/alpha/kernel/module.c b/arch/alpha/kernel/module.c index ebc3c89..8ceec20 100644 --- a/arch/alpha/kernel/module.c +++ b/arch/alpha/kernel/module.c @@ -73,6 +73,8 @@ process_reloc_for_got(Elf64_Rela *rela, } g = kmalloc (sizeof (*g), GFP_KERNEL); + if (g == NULL) + return; g->next = chains[r_sym].next; g->r_addend = r_addend; g->got_offset = *poffset; -- To unsubscribe from this list: send the line "unsubscribe linux-alpha" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html