X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=src%2Fdbus-target.c;h=55cf862de068d9caf65eb648c0adf315d74cef7d;hb=d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632;hp=45f0d31f05de9efe4a4ec13cb32d35a1b67fb2cc;hpb=4288f619215e3dda0b75113d78e4fb7ba219ed58;p=elogind.git
diff --git a/src/dbus-target.c b/src/dbus-target.c
index 45f0d31f0..55cf862de 100644
--- a/src/dbus-target.c
+++ b/src/dbus-target.c
@@ -1,4 +1,4 @@
-/*-*- Mode: C; c-basic-offset: 8 -*-*/
+/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
/***
This file is part of systemd.
@@ -19,8 +19,11 @@
along with systemd; If not, see .
***/
+#include
+
#include "dbus-unit.h"
#include "dbus-target.h"
+#include "dbus-common.h"
#define BUS_TARGET_INTERFACE \
" \n" \
@@ -32,16 +35,21 @@
BUS_UNIT_INTERFACE \
BUS_TARGET_INTERFACE \
BUS_PROPERTIES_INTERFACE \
+ BUS_PEER_INTERFACE \
BUS_INTROSPECTABLE_INTERFACE \
"\n"
-const char bus_target_interface[] = BUS_TARGET_INTERFACE;
+#define INTERFACES_LIST \
+ BUS_UNIT_INTERFACES_LIST \
+ "org.freedesktop.systemd1.Target\0"
+
+const char bus_target_interface[] _introspect_("Target") = BUS_TARGET_INTERFACE;
-DBusHandlerResult bus_target_message_handler(Unit *u, DBusMessage *message) {
- const BusProperty properties[] = {
- BUS_UNIT_PROPERTIES,
- { NULL, NULL, NULL, NULL, NULL }
+DBusHandlerResult bus_target_message_handler(Unit *u, DBusConnection *c, DBusMessage *message) {
+ const BusBoundProperties bps[] = {
+ { "org.freedesktop.systemd1.Unit", bus_unit_properties, u },
+ { NULL, }
};
- return bus_default_message_handler(u->meta.manager, message, INTROSPECTION, properties);
+ return bus_default_message_handler(c, message, INTROSPECTION, INTERFACES_LIST, bps);
}