Detectin mainloop integration

Havoc Pennington hp at redhat.com
Fri Sep 28 08:55:33 PDT 2007


Hi,

Some thoughts:

1) are setup/unsetup really doing a refcount? (so they have to be
called a paired number of times?) I would say they should

2) is is_setup() useful?

3) should we add API to libdbus that is more like:
   typedef struct {
          DBusSetupConnectionFunc setup_connection_func;
          DBusSetupServerFunc setup_server_func;
          void (* padding1) (void);
          ...
   } DBusIntegrationFunctions;
   dbus_set_integration(const char *name, const
DBusIntegrationFunctions *funcs);

   An example of the difference here is that on calling
dbus_connection_open() or dbus_bus_get(), the returned connection
would already be integrated. For dbus_connection_open_private()
probably it would not be. Without this approach, we probably need a
bus_get() equivalent at least in the glib integration lib.

  This may be a "future elaboration" though, we could do just a
setup_with_g_main() split-out from dbus-glib for now.

4) I'd be inclined to stick this glib integration lib into the main
dbus tarball. It does not seem big enough to me to mess with as a
separate thing. I'm also inclined to eventually merge some parts of
hippo-dbus-helper or some kind of C convenience lib into the main dbus
tarball. Are there big downsides to doing so?

Havoc


More information about the dbus mailing list