* grub-core/loader/i386/bsd.c (grub_bsd_load): Handle relocator failure
if it happens.
This commit is contained in:
parent
5ff1d945ed
commit
d0b526b277
2 changed files with 11 additions and 1 deletions
|
@ -1322,6 +1322,11 @@ grub_bsd_load (int argc, char *argv[])
|
|||
goto fail;
|
||||
|
||||
relocator = grub_relocator_new ();
|
||||
if (!relocator)
|
||||
{
|
||||
grub_file_close (file);
|
||||
goto fail;
|
||||
}
|
||||
|
||||
elf = grub_elf_file (file);
|
||||
if (elf)
|
||||
|
@ -1343,7 +1348,7 @@ grub_bsd_load (int argc, char *argv[])
|
|||
fail:
|
||||
|
||||
if (grub_errno != GRUB_ERR_NONE)
|
||||
grub_dl_unref (my_mod);
|
||||
grub_dl_unref (my_mod);
|
||||
|
||||
return grub_errno;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue