su also doesn't need issuid()

This commit is contained in:
Nicolas Williams
2017-04-17 16:43:35 -05:00
committed by Viktor Dukhovni
parent 7dfad1ab0b
commit 63a4c0d665

View File

@@ -364,7 +364,7 @@ main(int argc, char **argv)
else else
su_user = argv[optidx++]; su_user = argv[optidx++];
if (!issuid() && getuid() != 0) if (geteuid() != 0)
warnx("Not setuid and you are not root, expect this to fail"); warnx("Not setuid and you are not root, expect this to fail");
pwd = k_getpwnam(su_user); pwd = k_getpwnam(su_user);