[patch] Fix refcounting and locking in dbus-connection
Havoc Pennington
hp at redhat.com
Tue Sep 5 15:03:53 PDT 2006
John (J5) Palmieri wrote:
> I removed it from the files in bus/ and make check still passed. We
> still need it for dbus-connection.c and dbus-bus.c but I could rename it
> to _dbus_connection_close_shared or _dbus_connection_close_no_check.
>
It's fine for dbus-connection.c / dbus-bus.c (basically it should only
be used by the "owner" of a shared connection). close_shared might be a
better name, indeed - it could even have an assert(connection->shared)
in it. Though... does that "shared" flag mean shared in the sense of
dbus-connection.c or shared in the sense of dbus-bus.c or both?
Come to think of it if dbus-bus.c does a connection_open() instead of
open_private() then some connections could be "owned" by both bus.c and
connection.c - did you already handle that case? I'm too lazy to look at
the patch again ;-)
Havoc
More information about the dbus
mailing list