Revert 1.381 which wasn't a style change after all
authorFabian Keil <fk@fabiankeil.de>
Mon, 23 Jul 2012 12:55:25 +0000 (12:55 +0000)
committerFabian Keil <fk@fabiankeil.de>
Mon, 23 Jul 2012 12:55:25 +0000 (12:55 +0000)
jcc.c

diff --git a/jcc.c b/jcc.c
index face11b..91173c5 100644 (file)
--- a/jcc.c
+++ b/jcc.c
@@ -1,4 +1,4 @@
-const char jcc_rcs[] = "$Id: jcc.c,v 1.381 2012/07/23 12:40:52 fabiankeil Exp $";
+const char jcc_rcs[] = "$Id: jcc.c,v 1.382 2012/07/23 12:42:53 fabiankeil Exp $";
 /*********************************************************************
  *
  * File        :  $Source: /cvsroot/ijbswa/current/jcc.c,v $
@@ -3193,9 +3193,12 @@ int main(int argc, char **argv)
       {
          log_error(LOG_LEVEL_FATAL, "Cannot setgid(): Insufficient permissions.");
       }
-      if ((NULL != grp) && setgroups(1, &grp->gr_gid))
+      if (NULL != grp)
       {
-         log_error(LOG_LEVEL_FATAL, "setgroups() failed: %E");
+         if (setgroups(1, &grp->gr_gid))
+         {
+            log_error(LOG_LEVEL_FATAL, "setgroups() failed: %E");
+         }
       }
       else if (initgroups(pw->pw_name, pw->pw_gid))
       {