setuidgid: set all groups, not just the primary one; mgetgroups: new module
authorJim Meyering <jim@meyering.net>
Thu, 5 Jul 2007 15:42:29 +0000 (17:42 +0200)
committerJim Meyering <jim@meyering.net>
Fri, 6 Jul 2007 05:44:39 +0000 (07:44 +0200)
commite0066f36c22dce02f9d6327cb881ee7eec6e7539
tree39c5d9c47df892a1ab845e11fc89b93b8e9b6a1a
parentb8031ff7c74b153f1e929c059e42532a9771eb74
setuidgid: set all groups, not just the primary one;  mgetgroups: new module

I wanted to use the xgetgroups function from id.c, so factored it out
and made it into a non-exiting function (hence the "m" prefix rather than "x").
* src/setuidgid.c (main): Use mgetgroups. Include "mgetgroups.h".

* src/id.c (xgetgroups): Remove function.
Include "mgetgroups.h".
(print_group_list): Use mgetgroups, not xgetgroups.

* gl/modules/mgetgroups: New module.
* gl/lib/mgetgroups.c: New file.  mgetgroups is derived from
id.c's xgetgroups function.
* bootstrap.conf (gnulib_modules): Add mgetgroups.
* gl/m4/mgetgroups.m4: New file.
* gl/lib/mgetgroups.h: New file.
12 files changed:
ChangeLog
bootstrap.conf
gl/lib/mgetgroups.c [new file with mode: 0644]
gl/lib/mgetgroups.h [new file with mode: 0644]
gl/m4/mgetgroups.m4 [new file with mode: 0644]
gl/modules/mgetgroups [new file with mode: 0644]
lib/.cvsignore
lib/.gitignore
m4/.cvsignore
m4/.gitignore
src/id.c
src/setuidgid.c