summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlban Crequy <alban.crequy@collabora.co.uk>2012-06-13 13:02:34 +0000
committerRodrigo Moya <rodrigo@gnome-db.org>2012-06-13 16:00:32 +0200
commit47fbdfed3d6748a56d1e1ed4fb9a85eaa0c70ecf (patch)
treef39fde9b5219e18fcb8196ddb9273a14bb098a4f
parent76931c83fd0b2d8983bc19629cb524bfcbf05b76 (diff)
downloaddbus-47fbdfed3d6748a56d1e1ed4fb9a85eaa0c70ecf.tar.gz
clean match rules and well-known names in the kernel when a peer disconnect
-rw-r--r--bus/connection.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/bus/connection.c b/bus/connection.c
index 89111d90..3f1d4122 100644
--- a/bus/connection.c
+++ b/bus/connection.c
@@ -30,6 +30,7 @@
#include "signals.h"
#include "expirelist.h"
#include "selinux.h"
+#include "driver-afbus.h"
#include <dbus/dbus-list.h>
#include <dbus/dbus-hash.h>
#include <dbus/dbus-timeout.h>
@@ -221,6 +222,7 @@ bus_connection_disconnected (DBusConnection *connection)
BusConnectionData *d;
BusService *service;
BusMatchmaker *matchmaker;
+ DBusError error;
d = BUS_CONNECTION_DATA (connection);
_dbus_assert (d != NULL);
@@ -237,6 +239,11 @@ bus_connection_disconnected (DBusConnection *connection)
d->proxy_connection = NULL;
}
+ dbus_error_init (&error);
+
+ if (!bus_driver_afbus_disconnected(connection, &error))
+ dbus_error_free (&error);
+
/* Delete our match rules */
if (d->n_match_rules > 0)
{