summaryrefslogtreecommitdiffstats
path: root/login-utils
diff options
context:
space:
mode:
Diffstat (limited to 'login-utils')
-rw-r--r--login-utils/last.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/login-utils/last.c b/login-utils/last.c
index be744b079..303adeacd 100644
--- a/login-utils/last.c
+++ b/login-utils/last.c
@@ -600,7 +600,7 @@ static int is_phantom(const struct last_control *ctl, struct utmpx *ut)
if (ut->ut_tv.tv_sec < ctl->boot_time.tv_sec)
return 1;
- ut->ut_user[__UT_NAMESIZE - 1] = '\0';
+ ut->ut_user[sizeof(ut->ut_user) - 1] = '\0';
pw = getpwnam(ut->ut_user);
if (!pw)
return 1;