]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
.
authorJim Meyering <jim@meyering.net>
Tue, 11 Oct 1994 01:56:53 +0000 (01:56 +0000)
committerJim Meyering <jim@meyering.net>
Tue, 11 Oct 1994 01:56:53 +0000 (01:56 +0000)
src/id.c
src/su.c

index 92f2bd6c7e47c82194634ff5092dea0df25fe771..9f1daa88aa76c9312d2db01d311d842d67fa41fa 100644 (file)
--- a/src/id.c
+++ b/src/id.c
@@ -240,7 +240,7 @@ print_group_list (username)
       print_group (egid);
     }
 
-#ifdef NGROUPS_MAX
+#if defined(NGROUPS_MAX) && defined(HAVE_GETGROUPS)
   {
     int ngroups;
     GETGROUPS_T *groups;
@@ -313,7 +313,7 @@ print_full_info (username)
        printf ("(%s)", grp->gr_name);
     }
 
-#ifdef NGROUPS_MAX
+#if defined(NGROUPS_MAX) && defined(HAVE_GETGROUPS)
   {
     int ngroups;
     GETGROUPS_T *groups;
index 4a1640767afe56379f8636e4556cb2ea601f71cd..a447a1a506f5f0c8319b6afff54a0ca090c31e62 100644 (file)
--- a/src/su.c
+++ b/src/su.c
@@ -77,7 +77,7 @@
 #include <grp.h>
 #include "system.h"
 
-#ifdef HAVE_SYSLOG_H
+#if defined(HAVE_SYSLOG_H) && defined(HAVE_SYSLOG)
 #include <syslog.h>
 static void log_su ();
 #else /* !HAVE_SYSLOG_H */
@@ -397,7 +397,7 @@ static void
 change_identity (pw)
      struct passwd *pw;
 {
-#ifdef NGROUPS_MAX
+#ifdef HAVE_INITGROUPS
   errno = 0;
   if (initgroups (pw->pw_name, pw->pw_gid) == -1)
     error (1, errno, "cannot set groups");