mirror of
https://github.com/dynup/kpatch
synced 2024-12-22 21:22:07 +00:00
Merge pull request #1079 from julien-thierry/fix-norela-toc
create-diff-object: Handle ppc64le toc with only constants
This commit is contained in:
commit
b4d2a4e504
@ -177,6 +177,10 @@ static struct rela *toc_rela(const struct rela *rela)
|
|||||||
rela->type != R_PPC64_TOC16_LO_DS)
|
rela->type != R_PPC64_TOC16_LO_DS)
|
||||||
return (struct rela *)rela;
|
return (struct rela *)rela;
|
||||||
|
|
||||||
|
/* Only constants in toc */
|
||||||
|
if (!rela->sym->sec->rela)
|
||||||
|
return NULL;
|
||||||
|
|
||||||
/* Will return NULL for .toc constant entries */
|
/* Will return NULL for .toc constant entries */
|
||||||
return find_rela_by_offset(rela->sym->sec->rela,
|
return find_rela_by_offset(rela->sym->sec->rela,
|
||||||
(unsigned int)rela->addend);
|
(unsigned int)rela->addend);
|
||||||
|
Loading…
Reference in New Issue
Block a user