diff --git a/ChangeLog b/ChangeLog index 4a19338f2..16a2c7fbc 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2013-11-08 Vladimir Serbinenko + + * grub-core/loader/multiboot_mbi2.c (grub_multiboot_add_module): Fix + NULL pointer dereference. + 2013-11-07 Vladimir Serbinenko * grub-core/Makefile.am: Do not include libgcc.h when compiling with diff --git a/grub-core/loader/multiboot_mbi2.c b/grub-core/loader/multiboot_mbi2.c index 6a6be77e2..cdbeef92c 100644 --- a/grub-core/loader/multiboot_mbi2.c +++ b/grub-core/loader/multiboot_mbi2.c @@ -978,10 +978,7 @@ grub_multiboot_add_module (grub_addr_t start, grub_size_t size, if (modules_last) modules_last->next = newmod; else - { - modules = newmod; - modules_last->next = NULL; - } + modules = newmod; modules_last = newmod; modcnt++;