setgroups() moved?

Chris Adams cmadams at
Wed Feb 23 16:37:09 UTC 2005

Once upon a time, Jakub Jelinek <jakub at> said:
> You haven't read the man page carefully:
>        #include <sys/types.h>
>        #include <unistd.h>
>        int getgroups(int size, gid_t list[]);
>        #include <grp.h>
>        int setgroups(size_t size, const gid_t *list);
> I.e. for getgroups you need sys/types.h and unistd.h and for setgroups
> also grp.h.

Why is it done this way?  The other OSes I have access to (Tru64
4.0G/5.1A and Solaris 9) don't require grp.h to get setgroups().

Chris Adams <cmadams at>
Systems and Network Administrator - HiWAAY Internet Services
I don't speak for anybody but myself - that's enough trouble.

More information about the fedora-devel-list mailing list