diff options
author | tmm <tmm@FreeBSD.org> | 2002-09-14 12:14:24 +0000 |
---|---|---|
committer | tmm <tmm@FreeBSD.org> | 2002-09-14 12:14:24 +0000 |
commit | 208c1cb7671941b62b6619e3c48279948e4f12a4 (patch) | |
tree | 790f773b5ef64c358cec44c772b6b19342c33fa9 /libexec | |
parent | 0590c43070aac7fb636a1f4c4b94469046a317a0 (diff) | |
download | FreeBSD-src-208c1cb7671941b62b6619e3c48279948e4f12a4.zip FreeBSD-src-208c1cb7671941b62b6619e3c48279948e4f12a4.tar.gz |
Return an error if a symbol is not found in reloc_jmpslots() instead of
crashing.
Diffstat (limited to 'libexec')
-rw-r--r-- | libexec/rtld-elf/sparc64/reloc.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libexec/rtld-elf/sparc64/reloc.c b/libexec/rtld-elf/sparc64/reloc.c index b26b119..7a43ce4 100644 --- a/libexec/rtld-elf/sparc64/reloc.c +++ b/libexec/rtld-elf/sparc64/reloc.c @@ -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); } |