From dcd675cabcf1fad8e2eecd326ae17a8c95387e82 Mon Sep 17 00:00:00 2001 From: Aaron Merey Date: Wed, 31 Dec 2025 21:50:36 -0500 Subject: [PATCH] doc: Add gelf_getdyn.3 Signed-off-by: Aaron Merey --- doc/Makefile.am | 1 + doc/gelf_getdyn.3 | 77 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 78 insertions(+) create mode 100644 doc/gelf_getdyn.3 diff --git a/doc/Makefile.am b/doc/Makefile.am index 38357429..fbbd254f 100644 --- a/doc/Makefile.am +++ b/doc/Makefile.am @@ -94,6 +94,7 @@ notrans_dist_man3_MANS= elf32_checksum.3 \ gelf_fsize.3 \ gelf_getchdr.3 \ gelf_getclass.3 \ + gelf_getdyn.3 \ gelf_getehdr.3 \ gelf_getphdr.3 \ gelf_getrel.3 \ diff --git a/doc/gelf_getdyn.3 b/doc/gelf_getdyn.3 new file mode 100644 index 00000000..04f58287 --- /dev/null +++ b/doc/gelf_getdyn.3 @@ -0,0 +1,77 @@ +.TH GELF_GETDYN 3 2025-12-30 "Libelf" "Libelf Programmer's Manual" + +.SH NAME +gelf_getdyn \- Get class\-independent information from dynamic table at the given index + +.SH SYNOPSIS +.nf +.B #include + +.BI "GElf_Dyn *gelf_getdyn (Elf_Data *" data ", int " ndx ", GElf_Dyn *" dst ");" + +.SH DESCRIPTION +Retrieve a dynamic table entry from +.I data +at index +.I ndx +and store it in a class\-independent representation pointed to by +.IR dst . + +.PP +.I data +must be an +.B Elf_Data* +associated with a section of type +.B SHT_DYNAMIC + +.SH PARAMETERS +.TP +.I data +Pointer to an +.B Elf_Data +of a section with type +.BR SHT_DYNAMIC . +.I data->d_type +should be +.BR ELF_T_DYN . + +.TP +.I ndx +Zero\-based index of the requested dynamic table entry within +.IR data . + +.TP +.I dst +Pointer to a caller\-provided +.B GElf_Dyn +structure for storing the requested dynamic table entry. Must not be NULL. + +.SH RETURN VALUE +On success, this function updates +.I dst +with the requested dynamic table entry and returns +.IR dst . +On failure, it returns NULL and sets elf_errno. If +.I data +is NULL, then NULL is returned without setting elf_errno. + +.SH SEE ALSO +.BR gelf_update_dyn (3), +.BR libelf (3), +.BR elf (5) + +.SH ATTRIBUTES +.TS +allbox; +lbx lb lb +l l l. +Interface Attribute Value +T{ +.na +.nh +.BR gelf_getdyn () +T} Thread safety MT-Safe +.TE + +.SH REPORTING BUGS +Report bugs to or https://sourceware.org/bugzilla/. -- 2.47.3