Error out in put_got_entry if no dynamic symbol
This commit is contained in:
parent
dfed9babfc
commit
11747fe5d0
1 changed files with 2 additions and 0 deletions
2
tccelf.c
2
tccelf.c
|
@ -1013,6 +1013,8 @@ static unsigned long put_got_entry(TCCState *s1, int dyn_reloc_type,
|
|||
relocs_info[reloc_type].gotplt_entry == ALWAYS_GOTPLT_ENTRY)
|
||||
index = put_elf_sym(s1->dynsym, offset, size, info, 0,
|
||||
sym->st_shndx, name);
|
||||
else
|
||||
tcc_error("Runtime relocation without dynamic symbol: %s", name);
|
||||
put_elf_reloc(s1->dynsym, s1->got, got_offset, dyn_reloc_type, index);
|
||||
} else
|
||||
put_elf_reloc(symtab_section, s1->got, got_offset, dyn_reloc_type,
|
||||
|
|
Loading…
Reference in a new issue