drop_privileges: fix setuid check

The code attempts to check the return of setuid, but forgets to assign
the result variable.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
This commit is contained in:
Mike Frysinger 2013-09-17 00:23:26 -04:00
parent c54e232673
commit b8ea0699c4
1 changed files with 1 additions and 1 deletions

View File

@ -511,7 +511,7 @@ void drop_privileges(const char* user_name)
res = setgid(pw->pw_gid);
CHECK_RES_DIE(res, "setgid");
setuid(pw->pw_uid);
res = setuid(pw->pw_uid);
CHECK_RES_DIE(res, "setuid");
}