How to disconnect from dbus?

Havoc Pennington hp at pobox.com
Wed Jun 8 12:33:05 PDT 2011


Hi,

On Tue, Jun 7, 2011 at 2:13 PM, Krzysztof <dibo20 at wp.pl> wrote:
>   { Request the name of the bus }
>   ret := dbus_bus_request_name(FDBConn, 'im.pidgin.purple.PurpleInterface',
> DBUS_NAME_FLAG_REPLACE_EXISTING, @FDBErr);
>
> After this connection I get signals from pidgin, but what I must call to
> disconnect? Even if I call dbus_connection_close or dbus_connection_unref
> (which are not allowed for shared connections) I still get signals from
> pidgin.

To undo this, you'd dbus_bus_release_name() to drop the name,
presumably Pidgin just sends signals to anything with that name?

If you want to actually close the socket you have to use a private
connection rather than dbus_bus_get

Havoc


More information about the dbus mailing list