diff options
Diffstat (limited to 'dbus-job.c')
-rw-r--r-- | dbus-job.c | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/dbus-job.c b/dbus-job.c new file mode 100644 index 0000000000..0ac11bc1fb --- /dev/null +++ b/dbus-job.c @@ -0,0 +1,32 @@ +/*-*- Mode: C; c-basic-offset: 8 -*-*/ + +#include "dbus.h" +#include "log.h" + +static const char introspection[] = + DBUS_INTROSPECT_1_0_XML_DOCTYPE_DECL_NODE + "<node>" + " <interface name=\"org.freedesktop.systemd1.Job\">" + " </interface>" + BUS_PROPERTIES_INTERFACE + BUS_INTROSPECTABLE_INTERFACE + "</node>"; + +DBusHandlerResult bus_job_message_handler(DBusConnection *connection, DBusMessage *message, void *data) { + Manager *m = data; + + assert(connection); + assert(message); + assert(m); + + log_debug("Got D-Bus request: %s.%s() on %s", + dbus_message_get_interface(message), + dbus_message_get_member(message), + dbus_message_get_path(message)); + + return bus_default_message_handler(m, message, introspection, NULL); +} + +const DBusObjectPathVTable bus_job_vtable = { + .message_function = bus_job_message_handler +}; |