mirror of
https://git.savannah.gnu.org/git/guix.git
synced 2026-04-06 21:20:33 +02:00
syscalls: Adjust utmpx test.
Fixes <https://bugs.gnu.org/29426>. Reported by Adonay Felipe Nogueira <adfeno@hyperbola.info>. * tests/syscalls.scm ("utmpx-entries"): Check the value of (utmpx-entries entry) only for INIT_PROCESS, LOGIN_PROCESS, and USER_PROCESS entries.
This commit is contained in:
@@ -525,7 +525,12 @@
|
||||
(every (lambda (entry)
|
||||
(match (utmpx-user entry)
|
||||
((? string?)
|
||||
(or (eqv? (login-type BOOT_TIME) (utmpx-login-type entry))
|
||||
;; Ensure we have a valid PID for those entries where it
|
||||
;; makes sense.
|
||||
(or (not (memv (utmpx-login-type entry)
|
||||
(list (login-type INIT_PROCESS)
|
||||
(login-type LOGIN_PROCESS)
|
||||
(login-type USER_PROCESS))))
|
||||
(> (utmpx-pid entry) 0)))
|
||||
(#f ;might be DEAD_PROCESS
|
||||
#t)))
|
||||
|
||||
Reference in New Issue
Block a user