summaryrefslogtreecommitdiff
path: root/loginutils
diff options
context:
space:
mode:
Diffstat (limited to 'loginutils')
-rw-r--r--loginutils/login.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/loginutils/login.c b/loginutils/login.c
index b5e348b..256c7c4 100644
--- a/loginutils/login.c
+++ b/loginutils/login.c
@@ -61,7 +61,7 @@ static void read_or_build_utent(struct utmp *utptr, int run_by_root)
/* First, try to find a valid utmp entry for this process. */
/* If there is one, just use it. */
- while ((ut = getutent()) != NULL)
+ while ((ut = getutent()) != NULL) {
if (ut->ut_pid == pid && ut->ut_line[0] && ut->ut_id[0]
&& (ut->ut_type == LOGIN_PROCESS || ut->ut_type == USER_PROCESS)
) {
@@ -70,6 +70,7 @@ static void read_or_build_utent(struct utmp *utptr, int run_by_root)
memset(utptr->ut_host, 0, sizeof(utptr->ut_host));
return;
}
+ }
// Why? Do we require non-root to exec login from another
// former login process (e.g. login shell)? Some login's have