mirror of
https://github.com/troglobit/finit.git
synced 2026-10-01 13:33:09 +07:00
UTMP: Log to /var/log/wtmp as well as /run/utmp
The UTMP db tracks currently logged in users and WTMP is an audit trail of all user logins and logouts, as well as runlevel changes and reboot. Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
@@ -62,6 +62,7 @@ int utmp_set(int type, int pid, char *line, char *id, char *user)
|
||||
while (getutent())
|
||||
;
|
||||
result = pututline(&ut) ? 0 : 1;;
|
||||
updwtmp(_PATH_WTMP, &ut);
|
||||
endutent();
|
||||
|
||||
return result;
|
||||
|
||||
Reference in New Issue
Block a user