mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-11-29 08:52:46 +00:00
Return an error if a symbol is not found in reloc_jmpslots() instead of
crashing.
This commit is contained in:
parent
06be2aaa83
commit
a4823075e5
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=103315
@ -455,6 +455,8 @@ reloc_jmpslots(Obj_Entry *obj)
|
||||
where = (Elf_Addr *)(obj->relocbase + rela->r_offset);
|
||||
def = find_symdef(ELF_R_SYM(rela->r_info), obj, &defobj,
|
||||
true, NULL);
|
||||
if (def == NULL)
|
||||
return -1;
|
||||
target = (Elf_Addr)(defobj->relocbase + def->st_value);
|
||||
reloc_jmpslot(where, target, defobj);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user