chiark / gitweb /
Remove some dead code
[elogind.git] / src / core / dbus.c
index 08aff1fd2b03a64a92e8cac3028b1f58baedca4b..b92c7d0b99923cc739f7d224fcc3f03fca3bd435 100644 (file)
@@ -406,7 +406,7 @@ static DBusHandlerResult api_bus_message_filter(DBusConnection *connection, DBus
         dbus_error_free(&error);
 
         if (reply) {
-                if (!dbus_connection_send(connection, reply, NULL))
+                if (!bus_maybe_send_reply(connection, message, reply))
                         goto oom;
 
                 dbus_message_unref(reply);
@@ -978,9 +978,8 @@ static DBusConnection* manager_bus_connect_private(Manager *m, DBusBusType type)
         }
 
         return connection;
+
 fail:
-        if (connection)
-                dbus_connection_close(connection);
         dbus_error_free(&error);
         return NULL;
 }
@@ -1054,7 +1053,7 @@ fail:
 static int bus_init_private(Manager *m) {
         DBusError error;
         int r;
-        const char *const external_only[] = {
+        static const char *const external_only[] = {
                 "EXTERNAL",
                 NULL
         };