summaryrefslogtreecommitdiffstats
path: root/dbus/dbus-connection.c
diff options
context:
space:
mode:
authorHavoc Pennington <hp@redhat.com>2003-04-06 19:12:45 +0000
committerHavoc Pennington <hp@redhat.com>2003-04-06 19:12:45 +0000
commitbc8b061eec0fd9de6552a9e6118c40283863b6dc (patch)
tree473a4986783581d1b69364173fa48ee9ce8d505d /dbus/dbus-connection.c
parent6d54407dbb089dd0b0d8d79189b029c4d82bae81 (diff)
2003-04-06 Havoc Pennington <hp@pobox.com>
* dbus/dbus-threads.c: Redo how the fake debug mutexes are done so it detects deadlocks and also we actually init threads when debugging.
Diffstat (limited to 'dbus/dbus-connection.c')
-rw-r--r--dbus/dbus-connection.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/dbus/dbus-connection.c b/dbus/dbus-connection.c
index 1a00b702..e28e45b1 100644
--- a/dbus/dbus-connection.c
+++ b/dbus/dbus-connection.c
@@ -2053,6 +2053,10 @@ dbus_connection_dispatch (DBusConnection *connection)
* successful adds. i.e. if #FALSE is returned the net result
* should be that dbus_connection_set_watch_functions() has no effect,
* but the add_function and remove_function may have been called.
+ *
+ * @todo We need to drop the lock when we call the
+ * add/remove/toggled functions which can be a side effect
+ * of setting the watch functions.
*
* @param connection the connection.
* @param add_function function to begin monitoring a new descriptor.
@@ -2075,7 +2079,10 @@ dbus_connection_set_watch_functions (DBusConnection *connection,
dbus_mutex_lock (connection->mutex);
/* ref connection for slightly better reentrancy */
_dbus_connection_ref_unlocked (connection);
-
+
+ /* FIXME this can call back into user code, and we need to drop the
+ * connection lock when it does.
+ */
retval = _dbus_watch_list_set_functions (connection->watches,
add_function, remove_function,
toggled_function,