mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-12-02 19:22:47 +00:00
rtld: attempt to fix reloc_non_plt TLS allocation on MIPS
allocate_tls_offset returns true on success. The same issue existed on arm and was fixed in r345693. PR: 236880 MFC after: 1 month Sponsored by: The FreeBSD Foundation
This commit is contained in:
parent
dc412d2d4b
commit
650f4477a5
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=345694
@ -588,7 +588,7 @@ reloc_non_plt(Obj_Entry *obj, Obj_Entry *obj_rtld, int flags,
|
||||
if (def == NULL)
|
||||
return -1;
|
||||
|
||||
if (!defobj->tls_done && allocate_tls_offset(obj))
|
||||
if (!defobj->tls_done && !allocate_tls_offset(obj))
|
||||
return -1;
|
||||
|
||||
val += (Elf_Addr)def->st_value - TLS_DTP_OFFSET;
|
||||
@ -616,7 +616,7 @@ reloc_non_plt(Obj_Entry *obj, Obj_Entry *obj_rtld, int flags,
|
||||
if (def == NULL)
|
||||
return -1;
|
||||
|
||||
if (!defobj->tls_done && allocate_tls_offset(obj))
|
||||
if (!defobj->tls_done && !allocate_tls_offset(obj))
|
||||
return -1;
|
||||
|
||||
val += (Elf_Addr)(def->st_value + defobj->tlsoffset
|
||||
|
Loading…
Reference in New Issue
Block a user