1GENDERS_PARSE(3) LIBGENDERS GENDERS_PARSE(3)
2
3
4
6 genders_parse - determine errors with a genders file
7
9 #include <genders.h>
10
11 int genders_parse(genders_t handle, const char *filename, FILE
12 *stream);
13
15 genders_parse() parses the genders file indicated by filename and out‐
16 puts information to stream about parse errors in the genders file. If
17 filename is NULL, the default genders file will be checked. If stream
18 is NULL, information will be output to standard error.
19
21 On success, the number of parse errors discovered is returned. If
22 there are no errors, 0 is returned. On error, -1 is returned, and an
23 error code is returned in handle. The error code can be retrieved via
24 genders_errnum(3) , and a description of the error code can be
25 retrieved via genders_strerror(3). Error codes are defined in gen‐
26 ders.h.
27
29 GENDERS_ERR_NULLHANDLE
30 The handle parameter is NULL. The genders handle must be cre‐
31 ated with genders_handle_create(3).
32
33 GENDERS_ERR_OPEN
34 The genders file indicated by filename cannot be opened for
35 reading.
36
37 GENDERS_ERR_OVERFLOW
38 A line in the genders database exceeds the maximum allowed
39 length.
40
41 GENDERS_ERR_MAGIC
42 handle has an incorrect magic number. handle does not point to
43 a genders handle or handle has been destroyed by genders_han‐
44 dle_destroy(3).
45
47 /usr/include/genders.h
48
50 libgenders(3), genders_handle_create(3), genders_errnum(3), gen‐
51 ders_strerror(3)
52
53
54
55LLNL August 2003 GENDERS_PARSE(3)