Changeset 2584:f33bdd5d299d in roaraudio
- Timestamp:
- 09/06/09 16:15:35 (15 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
roard/roard.c
r2549 r2584 1382 1382 #ifdef ROAR_HAVE_SETGID 1383 1383 if ( setids & R_SETGID ) { 1384 if ( (grp = getgrnam(sock_grp)) == NULL ) { 1385 ROAR_ERR("Can not get GID for group %s: %s", sock_grp, strerror(errno)); 1386 return 1; 1387 } 1384 1388 if ( setgroups(0, (const gid_t *) NULL) == -1 ) { 1385 1389 ROAR_ERR("Can not clear supplementary group IDs: %s", strerror(errno)); … … 1450 1454 #ifdef ROAR_HAVE_SETUID 1451 1455 if ( setids & R_SETUID ) { 1456 if ( (pwd = getpwnam(sock_user)) == NULL ) { 1457 ROAR_ERR("Can not get UID for user %s: %s", sock_user, strerror(errno)); 1458 return 1; 1459 } 1452 1460 if ( !pwd || setuid(pwd->pw_uid) == -1 ) { 1453 1461 ROAR_ERR("Can not set UserID: %s", strerror(errno));
Note: See TracChangeset
for help on using the changeset viewer.