On Tue, Oct 25, 2016 at 11:01:08AM +0200, Pino Toscano wrote:
On Monday, 24 October 2016 18:23:26 CEST Richard W.M. Jones wrote:
> We do this by sending an Inhibit() message to logind and receiving a
> file descriptor back, which we hold open until the conversion
> completes (or fails). This is described here:
>
https://www.freedesktop.org/wiki/Software/systemd/inhibit/
>
> This adds an additional optional dependency on DBus since we use DBus
> to call the Inhibit() method.
>
> Reported-by: Chris Cowley.
Minor nitpick: "D-Bus" is the proper spelling.
OK I will change this.
The rest of the libdbus-1 implementation looks correct, checking
with
the API docs (and a bit the internals). Maybe could be worth using
the glib-based interface for it (dbus glib or GDBus).
Is there any particular advantage? The low level API is pretty
horrible to use, but in the end it wasn't too much code.
Rich.
--
Richard Jones, Virtualization Group, Red Hat
http://people.redhat.com/~rjones
Read my programming and virtualization blog:
http://rwmj.wordpress.com
Fedora Windows cross-compiler. Compile Windows programs, test, and
build Windows installers. Over 100 libraries supported.
http://fedoraproject.org/wiki/MinGW