]> git.pld-linux.org Git - packages/LPRng.git/blob - LPRng-setgroups.patch
updated to 3.7.5
[packages/LPRng.git] / LPRng-setgroups.patch
1 --- LPRng-3.7.4/src/common/utilities.c.setgroups        Thu Jun  7 13:21:44 2001
2 +++ LPRng-3.7.4/src/common/utilities.c  Thu Jun  7 13:26:48 2001
3 @@ -16,6 +16,12 @@
4  #include "getopt.h"
5  #include "errorcodes.h"
6  
7 +/* for setgroups */
8 +#ifndef _BSD_SOURCE
9 +#  define _BSD_SOURCE
10 +#endif
11 +#include <grp.h>
12 +
13  /**** ENDINCLUDE ****/
14  
15  /*
16 @@ -1287,6 +1291,10 @@
17         if( UID_root ){
18                 euid = geteuid();
19                 To_root();      /* set RUID/EUID to root */
20 +
21 +               /* drop supplemental groups - crutcher@redhat.com */
22 +               setgroups(0, NULL);
23 +
24                 status = setgid( DaemonGID );
25                 err = errno;
26                 if( To_uid( euid ) ){
This page took 0.079585 seconds and 3 git commands to generate.