Updated to fedora-glibc-20041119T0003
[glibc.git] / include / grp.h
blob5ed9c972f0307f0388f1c2215dba93b2070086e3
1 #ifndef _GRP_H
2 #include <grp/grp.h>
4 libc_hidden_proto (setgroups)
6 /* Now define the internal interfaces. */
7 extern int __getgrent_r (struct group *__resultbuf, char *buffer,
8 size_t __buflen, struct group **__result)
9 attribute_hidden;
10 extern int __old_getgrent_r (struct group *__resultbuf, char *buffer,
11 size_t __buflen, struct group **__result);
12 extern int __fgetgrent_r (FILE * __stream, struct group *__resultbuf,
13 char *buffer, size_t __buflen,
14 struct group **__result);
16 /* Search for an entry with a matching group ID. */
17 extern int __getgrgid_r (__gid_t __gid, struct group *__resultbuf,
18 char *__buffer, size_t __buflen,
19 struct group **__result);
20 extern int __old_getgrgid_r (__gid_t __gid, struct group *__resultbuf,
21 char *__buffer, size_t __buflen,
22 struct group **__result);
24 /* Search for an entry with a matching group name. */
25 extern int __getgrnam_r (__const char *__name, struct group *__resultbuf,
26 char *__buffer, size_t __buflen,
27 struct group **__result);
28 extern int __old_getgrnam_r (__const char *__name, struct group *__resultbuf,
29 char *__buffer, size_t __buflen,
30 struct group **__result);
32 struct parser_data;
33 extern int _nss_files_parse_grent (char *line, struct group *result,
34 struct parser_data *data,
35 size_t datalen, int *errnop);
36 libc_hidden_proto (_nss_files_parse_grent)
38 #define DECLARE_NSS_PROTOTYPES(service) \
39 extern enum nss_status _nss_ ## service ## _setgrent (int); \
40 extern enum nss_status _nss_ ## service ## _endgrent (void); \
41 extern enum nss_status _nss_ ## service ## _getgrgid_r \
42 (gid_t gid, struct group *grp, char *buffer, \
43 size_t buflen, int *errnop); \
44 extern enum nss_status _nss_ ## service ## _getgrnam_r \
45 (const char *name, struct group *grp, \
46 char *buffer, size_t buflen, int *errnop); \
47 extern enum nss_status _nss_ ## service ##_getgrent_r \
48 (struct group *result, char *buffer, size_t buflen, \
49 int *errnop); \
50 extern enum nss_status _nss_ ## service ##_initgroups_dyn \
51 (const char *user, gid_t group, long int *start, \
52 long int *size, gid_t **groupsp, long int limit, \
53 int *errnop);
55 DECLARE_NSS_PROTOTYPES (compat)
56 DECLARE_NSS_PROTOTYPES (files)
57 DECLARE_NSS_PROTOTYPES (hesiod)
58 DECLARE_NSS_PROTOTYPES (nis)
59 DECLARE_NSS_PROTOTYPES (nisplus)
61 #undef DECLARE_NSS_PROTOTYPES
62 #endif