table of contents
- experimental 0.194+20260315-1
| GELF_GETREL(3) | Libelf Programmer's Manual | GELF_GETREL(3) |
NAME¶
gelf_getrel, gelf_getrela - retrieve relocation entries as class-independent structures
SYNOPSIS¶
#include <gelf.h> GElf_Rel *gelf_getrel (Elf_Data *data, int ndx, GElf_Rel *dst); GElf_Rela *gelf_getrela(Elf_Data *data, int ndx, GElf_Rela *dst);
DESCRIPTION¶
The gelf_getrel() and gelf_getrela() functions translate the REL or RELA relocation entry at index ndx from data into a class-independent representation stored in *dst.
data must be the Elf_Data of a section whose type matches the function being called: SHT_REL for gelf_getrel() and SHT_RELA for gelf_getrela().
PARAMETERS¶
RETURN VALUE¶
On success, returns dst. On failure, returns NULL and sets elf_errno. If data is NULL, then NULL is returned without setting elf_errno.
SEE ALSO¶
elf_getdata(3), gelf_update_rel(3), gelf_update_rela(3), libelf(3), elf(5)
ATTRIBUTES¶
| Interface | Attribute | Value |
| gelf_getrel (), gelf_getrela () | Thread safety | MT-Safe |
REPORTING BUGS¶
Report bugs to <elfutils-devel@sourceware.org> or https://sourceware.org/bugzilla/.
| 2025-09-24 | Libelf |