summaryrefslogtreecommitdiffstats
path: root/source/lib/util.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>1998-07-29 05:05:36 +0000
committerAndrew Tridgell <tridge@samba.org>1998-07-29 05:05:36 +0000
commit8b25fe734166b76ceebf8d9543c706ebe0fddc96 (patch)
treeafcb4704429fd8eace29fbe503458a85afc00b88 /source/lib/util.c
parent19aa9a1c95d357e1041e9a3ece89d7bb3cc6f6ac (diff)
downloadsamba-8b25fe734166b76ceebf8d9543c706ebe0fddc96.tar.gz
samba-8b25fe734166b76ceebf8d9543c706ebe0fddc96.tar.xz
samba-8b25fe734166b76ceebf8d9543c706ebe0fddc96.zip
get rid of the runtime test for broken getgroups() and add a compile
time test instead. This also allows us to get rid of the igroups element of a couple of structures.
Diffstat (limited to 'source/lib/util.c')
-rw-r--r--source/lib/util.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/source/lib/util.c b/source/lib/util.c
index 8d1f6193189..35fb80be090 100644
--- a/source/lib/util.c
+++ b/source/lib/util.c
@@ -635,17 +635,17 @@ void close_sockets(void )
/****************************************************************************
determine whether we are in the specified group
****************************************************************************/
-BOOL in_group(gid_t group, int current_gid, int ngroups, int *groups)
+BOOL in_group(gid_t group, int current_gid, int ngroups, GID_T *groups)
{
- int i;
+ int i;
- if (group == current_gid) return(True);
+ if (group == current_gid) return(True);
- for (i=0;i<ngroups;i++)
- if (group == groups[i])
- return(True);
+ for (i=0;i<ngroups;i++)
+ if (group == groups[i])
+ return(True);
- return(False);
+ return(False);
}
/****************************************************************************