logind: add PrepareForShutdownWithMetadata signal
authorLuca Boccassi <bluca@debian.org>
Wed, 30 Aug 2023 18:51:13 +0000 (19:51 +0100)
committerLuca Boccassi <luca.boccassi@gmail.com>
Mon, 11 Sep 2023 11:56:00 +0000 (12:56 +0100)
commite4aab5cf1a00bbb73f325f4f785dd4171ccdae77
tree8543598e33ea45d8d3ecc75ac5858c9c509fea47
parentfd0a80427122c7bca0efb81ecc7ec11a483b4e6c
logind: add PrepareForShutdownWithMetadata signal

The existing signal doesn't say which type of shutdown is going to happen.
With the introduction of soft-reboot, it is useful to have this information
broadcasted, so that clients can choose to do different things based on the
reboot type.
Add a{sv} as the payload so that more metadata can be added later if
needed, without needing to add yet another signal.
Send both old and new signal for backward compatibility, and send the new
one first so that clients can just wait for the first one on both old and
new systems.
man/org.freedesktop.login1.xml
src/login/logind-action.c
src/login/logind-dbus.c
test/units/testsuite-82.sh