X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=libbb%2Fchange_identity.c;h=3f888f523bd1f53a97f7e824545b15b82af8c82f;hb=0aa6ba5d44af32d0bf460c8d92cda686bae64c92;hp=63c5ae1c8996d59d05a14629806abd8d60c23dfe;hpb=2e502914b0a2281e5d87b5093da5fb9e9759a601;p=oweals%2Fbusybox.git diff --git a/libbb/change_identity.c b/libbb/change_identity.c index 63c5ae1c8..3f888f523 100644 --- a/libbb/change_identity.c +++ b/libbb/change_identity.c @@ -28,14 +28,6 @@ * SUCH DAMAGE. */ -#include -#include -#include -#include -#include -#include -#include - #include "libbb.h" @@ -44,8 +36,7 @@ const char *change_identity_e2str(const struct passwd *pw) { if (initgroups(pw->pw_name, pw->pw_gid) == -1) return "cannot set groups"; - endgrent(); - + endgrent(); /* ?? */ xsetgid(pw->pw_gid); xsetuid(pw->pw_uid); return NULL; @@ -55,6 +46,6 @@ void change_identity(const struct passwd *pw) { const char *err_msg = change_identity_e2str(pw); - if(err_msg) + if (err_msg) bb_perror_msg_and_die("%s", err_msg); }