Lines Matching defs:gid
38 * When shutting down, the Xserver restores it's original uid/gid as
86 gid_t gid; /* Primary group */
139 originalUser.gid = getegid();
154 dmd->user.gid = (gid_t) -1;
455 dmd->user.gid = (gid_t) val;
483 if (chown(auth_file, user->uid, user->gid) < 0)
487 /* This gid dance is necessary in order to make sure
488 our "saved-set-gid" is 0 so that we can regain gid
490 The first step sets rgid to the user's gid and
491 makes the egid & saved-gid be 0. The second then
492 sets the egid to the users gid, but leaves the
493 saved-gid as 0. */
495 if (user->gid != (gid_t) -1) {
496 DtloginInfo("Setting gid to %d\n", user->gid);
498 if (setregid(user->gid, 0) < 0)
499 DtloginError("Error in setting regid to %d\n", user->gid);
501 if (setegid(user->gid) < 0)
502 DtloginError("Error in setting egid to %d\n", user->gid);