Bug 107024 - Why does ListActivatableNames say o.fd.DBus is activatable?
Summary: Why does ListActivatableNames say o.fd.DBus is activatable?
Status: RESOLVED MOVED
Alias: None
Product: dbus
Classification: Unclassified
Component: core (show other bugs)
Version: git master
Hardware: Other All
: lowest trivial
Assignee: D-Bus Maintainers
QA Contact: D-Bus Maintainers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-06-25 10:13 UTC by Simon McVittie
Modified: 2018-10-12 21:35 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description Simon McVittie 2018-06-25 10:13:07 UTC
Ever since ListActivatableNames() was added, it has included "org.freedesktop.DBus" as an activatable name:

commit 7628b541258d906e27e2000a402ed2d02383479c
Author: John (J5) Palmieri <johnp@redhat.com>
Date:   2006-07-14 01:17:59 +0000

    * bus/activation.[ch] (bus_activation_list_services): new function to
      get the list of services that can be activated
...
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,16 @@
+2006-07-13  Carlos Garcia Campos  <carlosgc@gnome.org>
+
+       * bus/activation.[ch] (bus_activation_list_services): new function to 
+       get the list of services that can be activated
...
--- a/bus/driver.c
+++ b/bus/driver.c
...
+    /* Include the bus driver in the list */
+    const char *v_STRING = DBUS_SERVICE_DBUS;
+    if (!dbus_message_iter_append_basic (&sub, DBUS_TYPE_STRING,
+                                        &v_STRING))
+      {
+       dbus_free_string_array (services);
+       dbus_message_unref (reply);
+       BUS_SET_OOM (error);
+       return FALSE;
+      }

This doesn't make a whole lot of sense to me: by calling ListActivatableNames() successfully, you've proved that o.fd.DBus exists, which means it's irrelevant whether it is activatable or not.

Does anyone know why it gets returned here? I think it would make sense in ListNames(), but not in ListActivatableNames().
Comment 1 Tom Gundersen 2018-07-03 11:25:03 UTC
I've also wondered about this. I just followed dbus-daemon on this when implementing the logic for dbus-broker, but note that it is particularly confusing that `StartServiceByName("org.freedesktop.DBus", 0)` fails with `org.freedesktop.DBus.Error.ServiceUnknown`.

That said, I am not aware of whether anything relies on the current behaviour, so can't actually help with an answer to your question.
Comment 2 GitLab Migration User 2018-10-12 21:35:09 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/dbus/dbus/issues/215.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.