From ce737f46cd8aa8bfa0b586d0a821c815835000ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Fri, 12 May 2017 14:25:17 -0400 Subject: test-login: make the test non-manual test-login.c is largely rewritten to use _cleanup_ and give more meaningful messages (function names are used instead of creative terms like "active session", so that when something unexpected is returned, it's much easier to see what function is responsible). The monitoring part is only activated if '-m' is passed on the command line. It runs against the information from /run/systemd/ in the live system, but that should be OK: logind/sd-login interface is supposed to be stable and both backwards and forwards compatible. If not running in a login session, some tests are skipped. Those two changes together mean that it's possible to run test-login in the test suite. Tests for sd_pid_get_{unit,user_unit,slice} are added. --- man/sd_session_is_active.xml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'man/sd_session_is_active.xml') diff --git a/man/sd_session_is_active.xml b/man/sd_session_is_active.xml index a6076b177a..f95e74ead6 100644 --- a/man/sd_session_is_active.xml +++ b/man/sd_session_is_active.xml @@ -184,8 +184,9 @@ sd_session_get_seat() may be used to determine the seat identifier of the seat the session identified by the specified session identifier belongs to. Note that not all - sessions are attached to a seat, this call will fail for them. The - returned string needs to be freed with the libc + sessions are attached to a seat, this call will fail (returning + -ENODATA) for them. The returned string needs + to be freed with the libc free3 call after use. -- cgit v1.2.1