summaryrefslogtreecommitdiff
path: root/bus/test.c
diff options
context:
space:
mode:
authorSimon McVittie <simon.mcvittie@collabora.co.uk>2011-01-20 15:48:07 +0000
committerSimon McVittie <simon.mcvittie@collabora.co.uk>2011-06-13 16:04:39 +0100
commitb8ccef11bbbc13b6ab74daaa76d9a9463f99b009 (patch)
tree9f6dc0894e493ce83bfe9c4300ec1273be3b09d3 /bus/test.c
parentc7ef3ead558e147db03e358ff37f630cac083c07 (diff)
downloaddbus-b8ccef11bbbc13b6ab74daaa76d9a9463f99b009.tar.gz
DBusConnection: ref the connection in the timeout handler
client_timeout_callback in bus/test.c refs the connection across the timeout invocation, which looks suspiciously like a workaround. If we make the timeout handler itself ref the connection, we won't need that, and can simplify timeout handling drastically. Bug: https://bugs.freedesktop.org/show_bug.cgi?id=33342 Reviewed-by: Thiago Macieira <thiago@kde.org>
Diffstat (limited to 'bus/test.c')
-rw-r--r--bus/test.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/bus/test.c b/bus/test.c
index 6efad6e0..95c7cfb8 100644
--- a/bus/test.c
+++ b/bus/test.c
@@ -76,12 +76,8 @@ client_timeout_callback (DBusTimeout *timeout,
{
DBusConnection *connection = data;
- dbus_connection_ref (connection);
-
/* can return FALSE on OOM but we just let it fire again later */
dbus_timeout_handle (timeout);
-
- dbus_connection_unref (connection);
}
static dbus_bool_t