]> git.ipfire.org Git - thirdparty/cups.git/blobdiff - scheduler/process.c
Merge changes from CUPS 1.5svn-r8950.
[thirdparty/cups.git] / scheduler / process.c
index 0f8d96a2b416b16fc7dfff1e1da461e60b4c116b..b19dc103c6cb9dc35f02cd82d35090133f22ab40 100644 (file)
@@ -491,8 +491,11 @@ cupsdStartProcess(
       * Reset group membership to just the main one we belong to.
       */
 
-      setgid(Group);
-      setgroups(1, &Group);
+      if (setgid(Group) && !RunUser)
+        exit(errno);
+
+      if (setgroups(1, &Group) && !RunUser)
+        exit(errno);
     }
 
    /*