1
2
3
4
5
6
7
8
9gd_naliases(3) GETDATA gd_naliases(3)
10
11
12
14 gd_naliases — report the number of aliases of a field in a Dirfile
15
16
18 #include <getdata.h>
19
20 unsigned int gd_naliases(DIRFILE *dirfile, const char *field_code);
21
22
24 The gd_naliases() function queries a dirfile(5) database specified by
25 dirfile and counts the number of aliases of the entry (including the
26 entry's name) specified by field_code.
27
28 The dirfile argument must point to a valid DIRFILE object previously
29 created by a call to gd_open(3).
30
31
33 Upon successful completion, gd_naliases() returns an unsigned integer
34 indicating the number of aliases of the specified field code in the
35 dirfile. If successful, this count will be at least one.
36
37 On error, this function returns zero and stores a negative-valued error
38 code in the DIRFILE object which may be retrieved by a subsequent call
39 to gd_error(3). Possible error codes are:
40
41 GD_E_BAD_CODE
42 The supplied field code was not found in the database.
43
44 GD_E_BAD_DIRFILE
45 The supplied dirfile was invalid.
46
47 A descriptive error string for the error may be obtained by calling
48 gd_error_string(3).
49
50
52 The gd_naliases() function appeared in GetData-0.8.0.
53
54
56 gd_aliases(3), gd_alias_target(3), gd_open(3), dirfile(5)
57
58
59
60Version 0.10.0 25 December 2016 gd_naliases(3)