#ifndef _GRP_H
#define _GRP_H 1
#include
__BEGIN_DECLS
#include
#define __need_size_t
#include
#if (defined __USE_XOPEN || defined __USE_XOPEN2K) && !defined __gid_t_defined
typedef __gid_t gid_t;
# define __gid_t_defined
#endif
struct group
{
char *gr_name;
char *gr_passwd;
__gid_t gr_gid;
char **gr_mem;
};
#if defined __USE_SVID || defined __USE_GNU
# define __need_FILE
# include
#endif
#if defined __USE_SVID || defined __USE_BSD || defined __USE_XOPEN_EXTENDED
extern void setgrent (void);
extern void endgrent (void);
extern struct group *getgrent (void);
#endif
#ifdef __USE_SVID
extern struct group *fgetgrent (FILE *__stream);
#endif
#ifdef __USE_GNU
extern int putgrent (__const struct group *__restrict __p,
FILE *__restrict __f);
#endif
extern struct group *getgrgid (__gid_t __gid);
extern struct group *getgrnam (__const char *__name);
#if defined __USE_POSIX || defined __USE_MISC
# ifdef __USE_MISC
# define NSS_BUFLEN_GROUP 1024
# endif
# ifdef __USE_GNU
extern int getgrent_r (struct group *__restrict __resultbuf,
char *__restrict __buffer, size_t __buflen,
struct group **__restrict __result);
# endif
extern int getgrgid_r (__gid_t __gid, struct group *__restrict __resultbuf,
char *__restrict __buffer, size_t __buflen,
struct group **__restrict __result);
extern int getgrnam_r (__const char *__restrict __name,
struct group *__restrict __resultbuf,
char *__restrict __buffer, size_t __buflen,
struct group **__restrict __result);
# ifdef __USE_SVID
extern int fgetgrent_r (FILE *__restrict __stream,
struct group *__restrict __resultbuf,
char *__restrict __buffer, size_t __buflen,
struct group **__restrict __result);
# endif
#endif
#ifdef __USE_BSD
# define __need_size_t
# include
extern int setgroups (size_t __n, __const __gid_t *__groups) __THROW;
extern int getgrouplist (__const char *__user, __gid_t __group,
__gid_t *__groups, int *__ngroups);
extern int initgroups (__const char *__user, __gid_t __group);
#endif
__END_DECLS
#endif
|