summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon McVittie <smcv@collabora.com>2020-02-25 12:59:48 +0000
committerSimon McVittie <smcv@collabora.com>2020-02-25 12:59:48 +0000
commitd251fe7850b3e80d0f72c6fd8d27db2a436e1bd2 (patch)
treece9b74600d57dcab1dc9f2bc6b8b3acab9ef6896
parentdf0c675b93c9521e1264ce906a70f239923c5b61 (diff)
parent2c6b0ad7f6bc0727717d455894f51cbb39b77bf3 (diff)
Merge branch 'cherry-pick-b034b83b' into 'dbus-1.12'dbus-1.12
[1.12] bus: Don't explicitly clear BusConnections.monitors See merge request dbus/dbus!142
-rw-r--r--bus/connection.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/bus/connection.c b/bus/connection.c
index 53605fa3..b3583433 100644
--- a/bus/connection.c
+++ b/bus/connection.c
@@ -537,9 +537,6 @@ bus_connections_unref (BusConnections *connections)
_dbus_assert (connections->n_incomplete == 0);
- /* drop all monitors */
- _dbus_list_clear (&connections->monitors);
-
/* drop all real connections */
while (connections->completed != NULL)
{
@@ -555,6 +552,10 @@ bus_connections_unref (BusConnections *connections)
_dbus_assert (connections->n_completed == 0);
+ /* disconnecting all the connections should have emptied the list of
+ * monitors (each link is removed in bus_connection_disconnected) */
+ _dbus_assert (connections->monitors == NULL);
+
bus_expire_list_free (connections->pending_replies);
_dbus_loop_remove_timeout (bus_context_get_loop (connections->context),