1nlist(3bsd)                          LOCAL                         nlist(3bsd)
2

NAME

4     nlist — retrieve symbol table name list from an executable file
5

LIBRARY

7     Utility functions from BSD systems (libbsd, -lbsd)
8

SYNOPSIS

10     #include <nlist.h>
11     (See libbsd(7) for include usage.)
12
13     int
14     nlist(const char *filename, struct nlist *nl);
15

DESCRIPTION

17     The nlist() function retrieves name list entries from the symbol table of
18     an executable file (see elf(5)).  The argument nl is set to reference the
19     beginning of the list.  The list is preened of binary and invalid data;
20     if an entry in the name list is valid, the n_type and n_value for the en‐
21     try are copied into the list referenced by nl.  No other data is copied.
22     The last entry in the list is always NULL.
23

RETURN VALUES

25     The number of invalid entries is returned if successful; otherwise, if
26     the file filename does not exist or is not executable, or the nl pointer
27     is NULL, the returned value is -1.
28

SEE ALSO

30     elf(5)
31

HISTORY

33     A nlist() function appeared in Version 6 AT&T UNIX.
34
35BSD                             April 19, 1994                             BSD
Impressum