#ifndef __GRP_LOADED #define __GRP_LOADED 1 #pragma __nostandard #include /* ** Group database functions are available on Alpha only. ** They require version of OpenVMS Alpha higher than V7.3. */ #if __CRTL_VER >= 70301000 /* ************************************************************************* */ /* * * */ /* * HPE CONFIDENTIAL. This software is confidential proprietary software * */ /* * licensed by Hewlett Packard Enterprise Development, LP, and is not * */ /* * authorized to be used, duplicated or disclosed to anyone without the * */ /* * prior written permission of HPE. * */ /* * Copyright 2020 Hewlett Packard Enterprise Development, LP * */ /* * * */ /* * VMS SOFTWARE, INC. CONFIDENTIAL. This software is confidential * */ /* * proprietary software licensed by VMS Software, Inc., and is not * */ /* * authorized to be used, duplicated or disclosed to anyone without * */ /* * the prior written permission of VMS Software, Inc. * */ /* * Copyright 2020 VMS Software, Inc. * */ /* * * */ /* ************************************************************************* */ /**************************************************************************** ** ** - Group file access functions ** ***************************************************************************** ** Header introduced by the ISO POSIX-1 Standard ***************************************************************************** */ #ifdef __cplusplus extern "C" { #endif /* ** Naturally align data structures */ #pragma __member_alignment __save #pragma __member_alignment /* ** X/Open extensions for types */ #if defined _XOPEN_SOURCE || !defined _POSIX_C_SOURCE # if !defined __GID_T # define __GID_T 1 typedef __gid_t gid_t; # endif # if !defined __SIZE_T # define __SIZE_T 1 #ifdef __NAMESPACE_STD namespace std { #endif typedef __size_t size_t; #ifdef __NAMESPACE_STD } /* namespace std */ using std::size_t; #endif # endif #endif /* ** Define the group structure */ struct group { char *gr_name; __gid32_t gr_gid; char **gr_mem; }; /* ** Function prototypes. */ /* ** Applications compiled with long pointers will use ** __*64() flavour of the group database functions. */ #ifdef __INITIAL_POINTER_SIZE # if __INITIAL_POINTER_SIZE == 64 # define getgrent __getgrent64 # define getgrgid(__p1) __getgrgid64(__p1) # define getgrgid_r(__p1, __p2, __p3, __p4, __p5) \ __getgrgid_r64(__p1, __p2, __p3, __p4, __p5) # define getgrnam(__p1) __getgrnam64(__p1) # define getgrnam_r(__p1, __p2, __p3, __p4, __p5) \ __getgrnam_r64(__p1, __p2, __p3, __p4, __p5) #if __CRTL_VER >= 80500000 # define getgrent_r(__p1, __p2, __p3, __p4) \ __getgrent_r64(__p1, __p2, __p3, __p4) #endif /* 80500000 */ # endif #endif void endgrent(void); struct group *getgrent(void); void setgrent(void); struct group *getgrgid(__gid32_t __gid); int getgrgid_r(__gid32_t __gid, struct group *__grp, char *__buffer, __size_t __bufsize, struct group **__result); struct group *getgrnam(const char *__name); int getgrnam_r(const char *__name, struct group *__grp, char *__buffer, __size_t __bufsize, struct group **__result); #if __CRTL_VER >= 80500000 int getgrent_r(struct group *__grp, char *__buffer, __size_t __bufsize, struct group **__result); #endif /* 80500000 */ #ifdef __cplusplus } #endif #pragma __member_alignment __restore #endif /* __CRTL_VER >= 70301000 */ #pragma __standard #endif /* __GRP_LOADED */