[patch] gobject sender and pid

David Zeuthen david at fubar.dk
Mon Mar 13 12:19:59 PST 2006


On Mon, 2006-03-13 at 01:20 -0500, Havoc Pennington wrote:
> Suggest there should at least be accessors, rather than encouraging
> direct use of a magic object data name. But it's also an inherently
> unthreadsafe approach... maybe thread-local data? I swear we had a list
> thread a while back about how to do this though, with some conclusion.

Sure, the patch was just experimental to start some discussion; if it's
possible, like Ross and Robert suggests, to get dbus-binding-tool to
generate async method handlers for a subset (or even all) of my methods
it's fine by me.

> > I've also added dbus_bus_get_unix_process_id() as a convenience
> > function.. note that the bus have exported this method for ages now;
> > this is only convenience.
> 
> Suggest naming it to exactly match the dbus method, though
> get_connection_unix_process_id() is long... dbus-bus.h is unfortunately
> very ad hoc, but ideally let's not make it worse with new methods.

Well, I just tried to do what we already did for dbus_bus_get_unix_user
to at least make the mess look consistent :-)

> I'm kind of tempted to say let's kill dbus-bus.h in favor of having
> people generate it for their bindings. Or rather, I'm almost 100% sure
> dbus-bus.h should only have dbus_bus_get() and friends, no convenience
> methods. But it's not as simple as just deleting them since the new
> binding APIs would have to be added also.

And you would break at least HAL. OK, I do agree with you and will fix
HAL to not use these "convenience" methods soon, hope others will do the
same, and perhaps it's sensible to delete these for 1.0 or later. 

    David




More information about the dbus mailing list