summaryrefslogtreecommitdiffstats
path: root/lib/libulog
diff options
context:
space:
mode:
authored <ed@FreeBSD.org>2009-12-03 17:05:36 +0000
committered <ed@FreeBSD.org>2009-12-03 17:05:36 +0000
commit8ed84589ca5300180e8242effe8d9b72fe38280a (patch)
treeaacd1519b4e057808c4b1be81b7237ba37310918 /lib/libulog
parent03da910d8db01460d044c3ff90cc30e8a00c63d0 (diff)
downloadFreeBSD-src-8ed84589ca5300180e8242effe8d9b72fe38280a.zip
FreeBSD-src-8ed84589ca5300180e8242effe8d9b72fe38280a.tar.gz
Use USER_PROCESS instead of LOGIN_PROCESS.
POSIX isn't clear about how the fields should be used, but according to utmpx(5) on Linux, LOGIN_PROCESS refers to a TTY that's still running a getty.
Diffstat (limited to 'lib/libulog')
-rw-r--r--lib/libulog/ulog.h4
-rw-r--r--lib/libulog/ulog_getutxent.36
-rw-r--r--lib/libulog/ulog_getutxent.c2
3 files changed, 6 insertions, 6 deletions
diff --git a/lib/libulog/ulog.h b/lib/libulog/ulog.h
index fc95c3b..2551f91 100644
--- a/lib/libulog/ulog.h
+++ b/lib/libulog/ulog.h
@@ -71,11 +71,11 @@ struct ulog_utmpx {
#endif
#define OLD_TIME 2
#define NEW_TIME 3
-#if 0
#define USER_PROCESS 4
+#if 0
#define INIT_PROCESS 5
-#endif
#define LOGIN_PROCESS 6
+#endif
#define DEAD_PROCESS 7
#define SHUTDOWN_TIME 8
diff --git a/lib/libulog/ulog_getutxent.3 b/lib/libulog/ulog_getutxent.3
index 6b4bf01..5960a90 100644
--- a/lib/libulog/ulog_getutxent.3
+++ b/lib/libulog/ulog_getutxent.3
@@ -73,15 +73,15 @@ The
.Fa ut_type
field contains the type of the message, which may have one of the
following values:
-.Bl -tag -width LOGIN_PROCESS
+.Bl -tag -width SHUTDOWN_TIME
.It Dv EMPTY
No valid user accounting information.
.It Dv OLD_TIME
Identifies time when system clock changed.
.It Dv NEW_TIME
Identifies time after system clock changed.
-.It Dv LOGIN_PROCESS
-Identifies the session leader of a logged in user.
+.It Dv USER_PROCESS
+Identifies a process.
.It Dv DEAD_PROCESS
Identifies a session leader who has exited.
.It Dv SHUTDOWN_TIME
diff --git a/lib/libulog/ulog_getutxent.c b/lib/libulog/ulog_getutxent.c
index 082f60e..1dd464d 100644
--- a/lib/libulog/ulog_getutxent.c
+++ b/lib/libulog/ulog_getutxent.c
@@ -82,7 +82,7 @@ ulog_getutxent(void)
else if (MATCH(user, "") && MATCH(host, ""))
utx.ut_type = DEAD_PROCESS;
else if (!MATCH(user, ""))
- utx.ut_type = LOGIN_PROCESS;
+ utx.ut_type = USER_PROCESS;
else
utx.ut_type = EMPTY;
OpenPOWER on IntegriCloud