warp-vpn

point to point VPN implementation
git clone git://git.2f30.org/warp-vpn
Log | Files | Refs | README

commit cabcac9cc09199082f565952bcbb14de75c07acf
parent 7fba43aa92fe2ce395cb3f26cb3bd22cc78a17ea
Author: sin <sin@2f30.org>
Date:   Fri,  8 Apr 2016 10:07:52 +0100

style fix

Diffstat:
Mstun.c | 6+++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/stun.c b/stun.c @@ -244,9 +244,9 @@ revokeprivs(void) pw = getpwnam(NOPRIVUSER); if (!pw) logerr("no %s user", NOPRIVUSER); - if (setgroups(1, &pw->pw_gid) || - setresgid(pw->pw_gid, pw->pw_gid, pw->pw_gid) || - setresuid(pw->pw_uid, pw->pw_uid, pw->pw_uid)) + if (setgroups(1, &pw->pw_gid) < 0 || + setresgid(pw->pw_gid, pw->pw_gid, pw->pw_gid) < 0 || + setresuid(pw->pw_uid, pw->pw_uid, pw->pw_uid) < 0) logerr("failed to revoke privs"); }