chiark / gitweb /
exec: support unlimited resources
[elogind.git] / src / dbus-job.c
index 95367c4226afb1a610fcb716eb9c4edaed9ae31d..908ddba5379480672f9589294a395992f800700b 100644 (file)
 
 const char bus_job_interface[] _introspect_("Job") = BUS_JOB_INTERFACE;
 
+#define INTERFACES_LIST                              \
+        BUS_GENERIC_INTERFACES_LIST                  \
+        "org.freedesktop.systemd1.Job\0"
+
 #define INVALIDATING_PROPERTIES                 \
         "State\0"
 
@@ -99,7 +103,7 @@ static DBusHandlerResult bus_job_message_dispatch(Job *j, DBusConnection *connec
                 job_finish_and_invalidate(j, JOB_CANCELED);
 
         } else
-                return bus_default_message_handler(j->manager, connection, message, INTROSPECTION, properties);
+                return bus_default_message_handler(j->manager, connection, message, INTROSPECTION, INTERFACES_LIST, properties);
 
         if (reply) {
                 if (!dbus_connection_send(connection, reply, NULL))
@@ -194,6 +198,8 @@ static DBusHandlerResult bus_job_message_handler(DBusConnection *connection, DBu
 
                 if (r == -ENOENT) {
                         DBusError e;
+
+                        dbus_error_init(&e);
                         dbus_set_error_const(&e, DBUS_ERROR_UNKNOWN_OBJECT, "Unknown job");
                         return bus_send_error_reply(m, connection, message, &e, r);
                 }