aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSjoerd Simons <sjoerd.simons@collabora.co.uk>2009-10-19 23:58:43 +0800
committerSjoerd Simons <sjoerd.simons@collabora.co.uk>2009-10-20 00:04:52 +0800
commitf93812baa5b80a0f29421fefb425429dd837d2dd (patch)
tree7cdeaaedfc6307d4d108f878450fd1719cc7b397
parent812029d76b3e7a77c028d2c271696a9f7a691356 (diff)
downloadgsoc2013-empathy-f93812baa5b80a0f29421fefb425429dd837d2dd.tar
gsoc2013-empathy-f93812baa5b80a0f29421fefb425429dd837d2dd.tar.gz
gsoc2013-empathy-f93812baa5b80a0f29421fefb425429dd837d2dd.tar.bz2
gsoc2013-empathy-f93812baa5b80a0f29421fefb425429dd837d2dd.tar.lz
gsoc2013-empathy-f93812baa5b80a0f29421fefb425429dd837d2dd.tar.xz
gsoc2013-empathy-f93812baa5b80a0f29421fefb425429dd837d2dd.tar.zst
gsoc2013-empathy-f93812baa5b80a0f29421fefb425429dd837d2dd.zip
Unset pending_call explicitly instead of implicitly
-rw-r--r--libempathy/empathy-dispatcher.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/libempathy/empathy-dispatcher.c b/libempathy/empathy-dispatcher.c
index cc0c8198b..1cb418977 100644
--- a/libempathy/empathy-dispatcher.c
+++ b/libempathy/empathy-dispatcher.c
@@ -254,6 +254,9 @@ free_dispatcher_request_data (DispatcherRequestData *r)
if (r->request != NULL)
g_hash_table_unref (r->request);
+ if (r->pending_call != NULL)
+ tp_proxy_pending_call_cancel (r->pending_call);
+
g_slice_free (DispatcherRequestData, r);
}
@@ -285,8 +288,6 @@ free_connection_data (ConnectionData *cd)
for (l = cd->outstanding_requests ; l != NULL; l = g_list_delete_link (l,l))
{
- DispatcherRequestData *data = l->data;
- tp_proxy_pending_call_cancel (data->pending_call);
free_dispatcher_request_data (l->data);
}
@@ -1302,6 +1303,8 @@ dispatcher_request_channel_cb (TpConnection *connection,
EmpathyDispatcher *dispatcher =
EMPATHY_DISPATCHER (request_data->dispatcher);
+ request_data->pending_call = NULL;
+
dispatcher_connection_new_requested_channel (dispatcher,
request_data, object_path, NULL, error);
}
@@ -1438,6 +1441,8 @@ dispatcher_request_handles_cb (TpConnection *connection,
{
DispatcherRequestData *request_data = (DispatcherRequestData *) user_data;
+ request_data->pending_call = NULL;
+
if (error != NULL)
{
EmpathyDispatcher *dispatcher = EMPATHY_DISPATCHER (object);
@@ -1510,6 +1515,8 @@ dispatcher_create_channel_cb (TpConnection *connect,
EmpathyDispatcher *dispatcher =
EMPATHY_DISPATCHER (request_data->dispatcher);
+ request_data->pending_call = NULL;
+
dispatcher_connection_new_requested_channel (dispatcher,
request_data, object_path, properties, error);
}
@@ -1527,6 +1534,8 @@ dispatcher_ensure_channel_cb (TpConnection *connect,
EmpathyDispatcher *dispatcher =
EMPATHY_DISPATCHER (request_data->dispatcher);
+ request_data->pending_call = NULL;
+
dispatcher_connection_new_requested_channel (dispatcher,
request_data, object_path, properties, error);
}