]> Savannah Git Hosting - gnulib.git/commit
readutmp: Let callers distinguish LOGINs from USERs.
authorBruno Haible <bruno@clisp.org>
Wed, 19 Feb 2025 22:46:37 +0000 (23:46 +0100)
committerBruno Haible <bruno@clisp.org>
Fri, 7 Mar 2025 20:19:39 +0000 (21:19 +0100)
commitaaa3e334e594d88e1a2cceae136494c08a62a147
tree8356740ff9b14f70355c8a82915a91823f261037
parent12e98b4afecc2e53208e23dd62be6ba96e7f9aec
readutmp: Let callers distinguish LOGINs from USERs.

Reported by Paul Eggert in
<https://lists.gnu.org/archive/html/bug-gnulib/2025-02/msg00123.html>.

* lib/readutmp.h (LOGIN_PROCESS, UT_TYPE_LOGIN_PROCESS): New macros.
* lib/readutmp.c (read_utmp_from_systemd): Possibly use LOGIN_PROCESS
instead of USER_PROCESS, depending on the session's class.
lib/readutmp.c
lib/readutmp.h