Commit Graph

16 Commits

Author SHA1 Message Date
Lennart Poettering 7d5e9c0f60 util: define union dirent_storage and make use of it everywhere
Make sure to allocate enough space for readdir_r().

https://bugzilla.redhat.com/show_bug.cgi?id=858754
2012-09-19 22:21:09 +02:00
Lennart Poettering d18dff430b login: reshuffle meaning of require_active parameter 2012-09-12 08:30:35 +02:00
Colin Guthrie 2dc8f41a2b logind: Add a two new variables to the user session tracking file.
This counts 'online sessions' in addition to 'active sessions' and 'sessions'.

In this context, an 'online session' covers all session in the 'active' state
in addition to the explicit 'online' state.

This provides an easy machanism to determin all relevant sessions easily
(i.e. those that are not 'closing') and adds new semantics to the sd-login.c
APIs sd_uid_get_sessions() and sd_uid_get_seats() where the require_active
argument can be supplied as a value 2 which only lists sessions which are
'online'.

This functionality should allow client applications to avoid deadlocks where
they only exit when all sessions are complete, such as a the problem where
PulseAudio will not exit until all sessions are gone, but in itself prevents
the session from exiting.
2012-09-12 08:19:54 +02:00
Lennart Poettering 20747498c6 login: wrap CanTTY and CanGraphical seat attributes in libsystemd-login 2012-06-21 16:52:54 +02:00
Lennart Poettering 0604381b9d logind: introduce a state for session, being one of online, active, closing
online = logged in
active = logged in and session is in the fg
closing = nominally logged out but some left-over processes still around

Related to:

https://bugzilla.gnome.org/show_bug.cgi?id=677556
2012-06-21 16:14:53 +02:00
Lennart Poettering ba1261bc02 build-sys: fix built with --disable-logind 2012-05-30 22:25:01 +02:00
Lennart Poettering 5430f7f2bc relicense to LGPLv2.1 (with exceptions)
We finally got the OK from all contributors with non-trivial commits to
relicense systemd from GPL2+ to LGPL2.1+.

Some udev bits continue to be GPL2+ for now, but we are looking into
relicensing them too, to allow free copy/paste of all code within
systemd.

The bits that used to be MIT continue to be MIT.

The big benefit of the relicensing is that closed source code may now
link against libsystemd-login.so and friends.
2012-04-12 00:24:39 +02:00
Lennart Poettering fc8af9ff3f login: introduce sd_session_get_display() 2012-02-15 04:56:10 +01:00
Lennart Poettering 51f58f083a login: add new sd_session_get_type() and sd_session_get_class API calls 2012-02-14 21:54:00 +01:00
Lennart Poettering 50b1678aab sd-login: if NULL or 0 is passed as first parameter of the sd_xxx functions, work on objects of the calling process 2012-02-13 23:50:02 +01:00
Lennart Poettering ebda471d89 sd-login: teach sd_pid_get_unit() proper handling of instantiated services 2012-01-13 00:49:02 +01:00
Lennart Poettering eff406331a login: implement sd_session_get_service() 2012-01-05 23:14:22 +01:00
Lennart Poettering 94fb446e55 journald: store _SYSTEMD_UNIT= instead of _SYSTEMD_SERVICE= field, since processes might also be related to mount, swap or socket units, not just services 2012-01-04 15:35:30 +01:00
Lennart Poettering addedec48b logind: if we can't open /dev/tty0, assume there is no VT subsystem and don't pretend we could do VT switching 2012-01-03 21:47:54 +01:00
Lennart Poettering 9847946e12 login: introduce sd_pid_get_service() 2012-01-03 21:08:58 +01:00
Lennart Poettering 4bba9156da logind: move logind into its own subdirectory 2011-12-31 03:16:08 +01:00
Renamed from src/sd-login.c (Browse further)