[next] telepathy-glib: replace dbus_g_method_return_error + g_error_free with g_dbus_method_invocation_take_error

Simon McVittie smcv at kemper.freedesktop.org
Thu Mar 27 08:42:04 PDT 2014


Module: telepathy-glib
Branch: next
Commit: 6edb76facac9a902f8ecf6780aa5c06e73d567b6
URL:    http://cgit.freedesktop.org/telepathy/telepathy-glib/commit/?id=6edb76facac9a902f8ecf6780aa5c06e73d567b6

Author: Simon McVittie <simon.mcvittie at collabora.co.uk>
Date:   Tue Mar 11 17:51:36 2014 +0000

replace dbus_g_method_return_error + g_error_free with g_dbus_method_invocation_take_error

---

 telepathy-glib/base-client.c |   13 ++++---------
 1 file changed, 4 insertions(+), 9 deletions(-)

diff --git a/telepathy-glib/base-client.c b/telepathy-glib/base-client.c
index 443dc1e..6637a32 100644
--- a/telepathy-glib/base-client.c
+++ b/telepathy-glib/base-client.c
@@ -1759,8 +1759,7 @@ out:
   if (error == NULL)
     return;
 
-  dbus_g_method_return_error (context, error);
-  g_error_free (error);
+  g_dbus_method_invocation_take_error (context, error);
 }
 
 static void
@@ -1937,9 +1936,7 @@ out:
   if (error == NULL)
     return;
 
-  dbus_g_method_return_error (context, error);
-  g_error_free (error);
-
+  g_dbus_method_invocation_take_error (context, error);
 }
 
 static void
@@ -2255,8 +2252,7 @@ out:
   if (error == NULL)
     return;
 
-  dbus_g_method_return_error (context, error);
-  g_error_free (error);
+  g_dbus_method_invocation_take_error (context, error);
 }
 
 static void
@@ -2372,8 +2368,7 @@ _tp_base_client_add_request (TpSvcClientInterfaceRequests *iface,
 err:
   g_clear_object (&account);
 
-  dbus_g_method_return_error (context, error);
-  g_error_free (error);
+  g_dbus_method_invocation_take_error (context, error);
 }
 
 static void



More information about the telepathy-commits mailing list