summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon McVittie <simon.mcvittie@collabora.co.uk>2014-03-18 19:28:19 +0000
committerSimon McVittie <simon.mcvittie@collabora.co.uk>2014-03-27 15:40:39 +0000
commitb08a02ed5d6e0c57e3a17af2c2c2a3561b5eaabc (patch)
tree2124bc92ee0be3c822bc26bcceb1069a40ecb1da
parent8d1cfc63fb130c145d9727b617ea3210d0d31f1d (diff)
downloadtelepathy-mission-control-b08a02ed5d6e0c57e3a17af2c2c2a3561b5eaabc.tar.gz
Replace dbus_g_method_return_error with g_dbus_method_invocation_return_gerror
-rw-r--r--src/mcd-account-manager.c2
-rw-r--r--src/mcd-account.c4
-rw-r--r--src/mcd-dbusprop.c6
-rw-r--r--src/mcd-dispatch-operation.c16
-rw-r--r--src/mcd-dispatcher.c12
-rw-r--r--src/request.c4
6 files changed, 22 insertions, 22 deletions
diff --git a/src/mcd-account-manager.c b/src/mcd-account-manager.c
index 8330bcd4..bc0a0856 100644
--- a/src/mcd-account-manager.c
+++ b/src/mcd-account-manager.c
@@ -946,7 +946,7 @@ create_account_cb (McdAccountManager *account_manager, McdAccount *account,
if (G_UNLIKELY (error))
{
- dbus_g_method_return_error (context, (GError *)error);
+ g_dbus_method_invocation_return_gerror (context, (GError *)error);
return;
}
diff --git a/src/mcd-account.c b/src/mcd-account.c
index 04ef3355..2c4b273b 100644
--- a/src/mcd-account.c
+++ b/src/mcd-account.c
@@ -2155,7 +2155,7 @@ account_remove_delete_cb (GObject *source,
if (!mcd_account_delete_finish (MCD_ACCOUNT (source), res, &error))
{
- dbus_g_method_return_error (data->context, (GError *) error);
+ g_dbus_method_invocation_return_gerror (data->context, (GError *) error);
g_error_free (error);
return;
}
@@ -2635,7 +2635,7 @@ account_update_parameters_cb (McdAccount *account, GPtrArray *not_yet,
if (error != NULL)
{
- dbus_g_method_return_error (context, (GError *) error);
+ g_dbus_method_invocation_return_gerror (context, (GError *) error);
return;
}
diff --git a/src/mcd-dbusprop.c b/src/mcd-dbusprop.c
index 567b591a..c3e60a2c 100644
--- a/src/mcd-dbusprop.c
+++ b/src/mcd-dbusprop.c
@@ -198,7 +198,7 @@ dbusprop_set (TpSvcDBusProperties *self,
value, &error);
if (error)
{
- dbus_g_method_return_error (context, error);
+ g_dbus_method_invocation_return_gerror (context, error);
g_error_free (error);
return;
}
@@ -247,7 +247,7 @@ dbusprop_get (TpSvcDBusProperties *self,
if (error)
{
- dbus_g_method_return_error (context, error);
+ g_dbus_method_invocation_return_gerror (context, error);
g_error_free (error);
return;
}
@@ -322,7 +322,7 @@ dbusprop_get_all (TpSvcDBusProperties *self,
{
g_set_error (&error, TP_ERROR, TP_ERROR_INVALID_ARGUMENT,
"invalid interface: %s", interface_name);
- dbus_g_method_return_error (context, error);
+ g_dbus_method_invocation_return_gerror (context, error);
g_error_free (error);
return;
}
diff --git a/src/mcd-dispatch-operation.c b/src/mcd-dispatch-operation.c
index f8674e23..09732469 100644
--- a/src/mcd-dispatch-operation.c
+++ b/src/mcd-dispatch-operation.c
@@ -853,7 +853,7 @@ _mcd_dispatch_operation_finish (McdDispatchOperation *operation,
g_assert (approval->context != NULL);
DEBUG ("denying Claim call from %s",
dbus_g_method_get_sender (approval->context));
- dbus_g_method_return_error (approval->context, priv->result);
+ g_dbus_method_invocation_return_gerror (approval->context, priv->result);
approval->context = NULL;
break;
@@ -881,7 +881,7 @@ _mcd_dispatch_operation_finish (McdDispatchOperation *operation,
DEBUG ("HandleWith -> NotYours: wanted %s but "
"%s got it instead", approval->client_bus_name,
successful_handler);
- dbus_g_method_return_error (approval->context,
+ g_dbus_method_invocation_return_gerror (approval->context,
priv->result);
approval->context = NULL;
}
@@ -895,7 +895,7 @@ _mcd_dispatch_operation_finish (McdDispatchOperation *operation,
DEBUG ("HandleWith -> error: %s %d: %s",
g_quark_to_string (priv->result->domain),
priv->result->code, priv->result->message);
- dbus_g_method_return_error (approval->context, priv->result);
+ g_dbus_method_invocation_return_gerror (approval->context, priv->result);
approval->context = NULL;
}
@@ -941,7 +941,7 @@ dispatch_operation_handle_with (TpSvcChannelDispatchOperation *cdo,
if (!mcd_dispatch_operation_check_handle_with (self, handler_name, &error))
{
- dbus_g_method_return_error (context, error);
+ g_dbus_method_invocation_return_gerror (context, error);
g_error_free (error);
return;
}
@@ -985,7 +985,7 @@ claim_attempt_suitability_cb (GObject *source,
MCP_DISPATCH_OPERATION_POLICY (source), res, &error))
{
if (claim_attempt->context != NULL)
- dbus_g_method_return_error (claim_attempt->context, error);
+ g_dbus_method_invocation_return_gerror (claim_attempt->context, error);
claim_attempt->context = NULL;
g_error_free (error);
@@ -1013,7 +1013,7 @@ dispatch_operation_claim (TpSvcChannelDispatchOperation *cdo,
{
DEBUG ("Giving error to %s: %s", sender, self->priv->result->message);
- dbus_g_method_return_error (context, self->priv->result);
+ g_dbus_method_invocation_return_gerror (context, self->priv->result);
goto finally;
}
@@ -1724,7 +1724,7 @@ _mcd_dispatch_operation_set_handler_failed (McdDispatchOperation *self,
if (approval->type == APPROVAL_TYPE_HANDLE_WITH &&
!tp_strdiff (approval->client_bus_name, bus_name))
{
- dbus_g_method_return_error (approval->context, (GError *) error);
+ g_dbus_method_invocation_return_gerror (approval->context, (GError *) error);
approval->context = NULL;
approval_free (approval);
g_queue_delete_link (self->priv->approvals, iter);
@@ -2337,7 +2337,7 @@ _mcd_dispatch_operation_try_next_handler (McdDispatchOperation *self)
g_queue_pop_head (self->priv->approvals);
- dbus_g_method_return_error (approval->context, &gone);
+ g_dbus_method_invocation_return_gerror (approval->context, &gone);
approval->context = NULL;
approval_free (approval);
diff --git a/src/mcd-dispatcher.c b/src/mcd-dispatcher.c
index 00e5a272..a9c7f1ed 100644
--- a/src/mcd-dispatcher.c
+++ b/src/mcd-dispatcher.c
@@ -1288,7 +1288,7 @@ dispatcher_request_channel (McdDispatcher *self,
goto finally;
despair:
- dbus_g_method_return_error (context, error);
+ g_dbus_method_invocation_return_gerror (context, error);
g_error_free (error);
finally:
@@ -1443,7 +1443,7 @@ message_context_return_error (MessageContext *context, const GError *error)
if (context->dbus_context == NULL)
return;
- dbus_g_method_return_error (context->dbus_context, error);
+ g_dbus_method_invocation_return_gerror (context->dbus_context, error);
context->dbus_context = NULL;
}
@@ -1469,7 +1469,7 @@ message_context_free (gpointer ctx)
error = g_error_new_literal (TP_ERROR, TP_ERROR_TERMINATED,
"Channel request failed");
- dbus_g_method_return_error (context->dbus_context, error);
+ g_dbus_method_invocation_return_gerror (context->dbus_context, error);
g_error_free (error);
}
@@ -2016,7 +2016,7 @@ dispatcher_delegate_channels (
return;
error:
- dbus_g_method_return_error (context, error);
+ g_dbus_method_invocation_return_gerror (context, error);
g_error_free (error);
tp_clear_pointer (&ctx, delegate_channels_ctx_free);
@@ -2040,7 +2040,7 @@ present_handle_channel_cb (TpClient *client,
if (error != NULL)
{
- dbus_g_method_return_error (context, error);
+ g_dbus_method_invocation_return_gerror (context, error);
return;
}
@@ -2107,7 +2107,7 @@ dispatcher_present_channel (
return;
error:
- dbus_g_method_return_error (context, error);
+ g_dbus_method_invocation_return_gerror (context, error);
g_error_free (error);
}
diff --git a/src/request.c b/src/request.c
index 8786089b..02d7198b 100644
--- a/src/request.c
+++ b/src/request.c
@@ -691,7 +691,7 @@ _mcd_request_proceed (McdRequest *self,
"Proceed has already been called; stop calling it" };
if (context != NULL)
- dbus_g_method_return_error (context, &na);
+ g_dbus_method_invocation_return_gerror (context, &na);
return;
}
@@ -923,7 +923,7 @@ channel_request_cancel (TpSvcChannelRequest *iface,
}
else
{
- dbus_g_method_return_error (context, error);
+ g_dbus_method_invocation_return_gerror (context, error);
g_error_free (error);
}
}