dladdr1 (3) - Linux Manuals
dladdr1: translate address to symbolic information
NAME
dladdr, dladdr1 - translate address to symbolic information
SYNOPSIS
#define _GNU_SOURCE #include <dlfcn.h> int dladdr(void *addr, Dl_info *info); int dladdr1(void *addr, Dl_info *info, void **extra_info, int flags); Link with -ldl.
DESCRIPTION
The function dladdr() determines whether the address specified in addr is located in one of the shared objects loaded by the calling application. If it is, then dladdr() returns information about the shared object and symbol that overlaps addr. This information is returned in a Dl_info structure:
typedef struct {
If no symbol matching
addr
could be found, then
dli_sname
and
dli_saddr
are set to NULL.
The function
dladdr1()
is like
dladdr(),
but returns additional information via the argument
extra_info.
The information returned depends on the value specified in
flags,
which can have one of the following values: