aboutsummaryrefslogtreecommitdiffstats
path: root/guts/setfsgid.c
blob: b046c6f60204c5ce73b584c32d1d32ca2749bb0a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
/* 
 * static int
 * wrap_setfsgid(gid_t fsgid) {
 *	int rc = -1;
 */
	if (pseudo_euid == 0 ||
	    pseudo_egid == fsgid || pseudo_rgid == fsgid || pseudo_sgid == fsgid) {
		pseudo_fgid = fsgid;
		rc = 0;
	} else {
		rc = -1;
		errno = EPERM;
	}
/*	return rc;
 * }
 */