summaryrefslogtreecommitdiffstats
path: root/config/auto-aux/getgroups.c
diff options
context:
space:
mode:
Diffstat (limited to 'config/auto-aux/getgroups.c')
-rw-r--r--config/auto-aux/getgroups.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/config/auto-aux/getgroups.c b/config/auto-aux/getgroups.c
new file mode 100644
index 000000000..8520c5c67
--- /dev/null
+++ b/config/auto-aux/getgroups.c
@@ -0,0 +1,17 @@
+#include <sys/types.h>
+#include <sys/param.h>
+
+#ifdef NGROUPS
+
+int main()
+{
+ int gidset[NGROUPS];
+ if (getgroups(NGROUPS, gidset) == -1) return 1;
+ return 0;
+}
+
+#else
+
+int main() { return 1; }
+
+#endif