diff options
author | Xavier Claessens <xavier.claessens@collabora.co.uk> | 2012-05-10 11:14:25 +0200 |
---|---|---|
committer | Xavier Claessens <xavier.claessens@collabora.co.uk> | 2012-05-10 16:31:22 +0200 |
commit | 4dfca790804fff5411c316c34cca3494c44b340b (patch) | |
tree | 12458d8bdc9fe5db6ee965af4fc5f1c381ea789c /telepathy-glib/base-connection.c | |
parent | b09ac85e4056cfe6c4dc27bfdcf7f6b80f7e3538 (diff) | |
download | telepathy-glib-4dfca790804fff5411c316c34cca3494c44b340b.tar.gz |
Deprecate tp_handle(s)_ref/unref, tp_handle(s)_client_hold/release and tp_connection_unref_handles()
They are no-op now, so we can safely remove them all
Diffstat (limited to 'telepathy-glib/base-connection.c')
-rw-r--r-- | telepathy-glib/base-connection.c | 32 |
1 files changed, 2 insertions, 30 deletions
diff --git a/telepathy-glib/base-connection.c b/telepathy-glib/base-connection.c index 025149aa9..fe268fc8d 100644 --- a/telepathy-glib/base-connection.c +++ b/telepathy-glib/base-connection.c @@ -510,15 +510,7 @@ tp_base_connection_set_property (GObject *object, if (self->self_handle == new_self_handle) return; - if (self->self_handle != 0) - tp_handle_unref (priv->handles[TP_HANDLE_TYPE_CONTACT], - self->self_handle); - - self->self_handle = 0; - - if (new_self_handle != 0) - self->self_handle = tp_handle_ref (priv->handles[TP_HANDLE_TYPE_CONTACT], - new_self_handle); + self->self_handle = new_self_handle; tp_svc_connection_emit_self_handle_changed (self, self->self_handle); } @@ -592,12 +584,6 @@ tp_base_connection_dispose (GObject *object) g_assert ((self->status == TP_CONNECTION_STATUS_DISCONNECTED) || (self->status == TP_INTERNAL_CONNECTION_STATUS_NEW)); - if (self->self_handle != 0) - { - tp_handle_unref (self->priv->handles[TP_HANDLE_TYPE_CONTACT], - self->self_handle); - self->self_handle = 0; - } tp_base_connection_unregister (self); @@ -2605,11 +2591,7 @@ out: g_error_free (error); } - if (handles != NULL) - { - tp_handles_unref (handle_repo, handles); - g_array_unref (handles); - } + tp_clear_pointer (&handles, g_array_unref); } /** @@ -3630,22 +3612,12 @@ conn_requests_requestotron_validate_handle (TpBaseConnection *self, target_id_value); requested_properties = altered_properties; - - tp_handle_ref (handles, target_handle); } } conn_requests_offer_request (self, requested_properties, method, type, target_handle_type, target_handle, context); - /* If HandleType was not None, we got the relevant repo and took a reference - * to target_handle; release it before returning - */ - if (handles != NULL) - { - tp_handle_unref (handles, target_handle); - } - /* If we made a new table, we should destroy it, and whichever of the GValues * holding TargetHandle or TargetID we filled in. The other GValues are * borrowed from the supplied requested_properties table. |