[evolution-data-server/eclient] Make async functions void in EClient/EBookClient/ECalClient



commit 742b40c88390b8ffa683a26722c3c664f339a3f3
Author: Milan Crha <mcrha redhat com>
Date:   Wed Apr 27 13:14:24 2011 +0200

    Make async functions void in EClient/EBookClient/ECalClient

 addressbook/libebook/e-book-client.c               |  147 ++++--------
 addressbook/libebook/e-book-client.h               |   24 +-
 calendar/libecal/e-cal-client.c                    |  221 +++++------------
 calendar/libecal/e-cal-client.h                    |   38 ++--
 libedataserver/e-client.c                          |  253 ++++++++++----------
 libedataserver/e-client.h                          |   40 +++-
 tests/libebook/client/test-client-add-contact.c    |    8 +-
 tests/libebook/client/test-client-async.c          |   19 +--
 tests/libebook/client/test-client-get-book-view.c  |    5 +-
 .../libebook/client/test-client-get-capabilities.c |   44 +---
 tests/libebook/client/test-client-get-contact.c    |    7 +-
 .../client/test-client-get-required-fields.c       |   44 +---
 .../test-client-get-supported-auth-methods.c       |   44 +---
 .../client/test-client-get-supported-fields.c      |   44 +---
 tests/libebook/client/test-client-modify-contact.c |   13 +-
 .../client/test-client-remove-contact-by-uid.c     |    7 +-
 tests/libebook/client/test-client-remove-contact.c |    8 +-
 .../libebook/client/test-client-remove-contacts.c  |    8 +-
 tests/libebook/client/test-client-remove.c         |    6 +-
 tests/libecal/client/test-client-add-timezone.c    |   13 +-
 tests/libecal/client/test-client-create-object.c   |   30 +--
 tests/libecal/client/test-client-examine.c         |   78 ++-----
 .../client/test-client-get-attachment-uris.c       |    7 +-
 tests/libecal/client/test-client-get-free-busy.c   |    8 +-
 tests/libecal/client/test-client-get-object-list.c |   11 +-
 tests/libecal/client/test-client-get-view.c        |    5 +-
 tests/libecal/client/test-client-modify-object.c   |    7 +-
 tests/libecal/client/test-client-open.c            |   14 +-
 tests/libecal/client/test-client-receive-objects.c |    8 +-
 tests/libecal/client/test-client-refresh.c         |    7 +-
 tests/libecal/client/test-client-remove-object.c   |    8 +-
 tests/libecal/client/test-client-send-objects.c    |    8 +-
 32 files changed, 386 insertions(+), 798 deletions(-)
---
diff --git a/addressbook/libebook/e-book-client.c b/addressbook/libebook/e-book-client.c
index 2e99933..11ad4f2 100644
--- a/addressbook/libebook/e-book-client.c
+++ b/addressbook/libebook/e-book-client.c
@@ -122,7 +122,6 @@ get_client_error_from_gerror (GError *error, GError **client_error)
 	#undef err
 
 	g_return_if_fail (client_error != NULL);
-	g_return_if_fail (*client_error == NULL);
 
 	if G_LIKELY (error == NULL)
 		return;
@@ -900,10 +899,10 @@ e_book_client_is_self (EContact *contact)
 	return is_self;
 }
 
-static guint32
+static void
 book_client_open (EClient *client, gboolean only_if_exists, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	return e_client_proxy_call_boolean (client, only_if_exists, cancellable, callback, user_data, book_client_open,
+	e_client_proxy_call_boolean (client, only_if_exists, cancellable, callback, user_data, book_client_open,
 			e_gdbus_book_call_open,
 			e_gdbus_book_call_open_finish, NULL, NULL, NULL, NULL);
 }
@@ -934,10 +933,10 @@ book_client_open_sync (EClient *client, gboolean only_if_exists, GCancellable *c
 	return e_client_proxy_call_sync_boolean__void (client, only_if_exists, cancellable, error, e_gdbus_book_call_open_sync);
 }
 
-static guint32
+static void
 book_client_remove (EClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	return e_client_proxy_call_void (client, cancellable, callback, user_data, book_client_remove,
+	e_client_proxy_call_void (client, cancellable, callback, user_data, book_client_remove,
 			e_gdbus_book_call_remove,
 			e_gdbus_book_call_remove_finish, NULL, NULL, NULL, NULL);
 }
@@ -980,18 +979,15 @@ book_client_remove_sync (EClient *client, GCancellable *cancellable, GError **er
  * supports. The call is finished by e_book_client_get_capabilities_finish() from
  * the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Note: Usually is sufficient to use e_client_get_capabilities() or e_client_check_capability(),
  * which caches capabilities of a backend on the client side.
  *
  * Since: 3.2
  **/
-guint32
+void
 e_book_client_get_capabilities (EBookClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	return e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_book_client_get_capabilities,
+	e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_book_client_get_capabilities,
 			e_gdbus_book_call_get_capabilities,
 			NULL, NULL, e_gdbus_book_call_get_capabilities_finish, NULL, NULL);
 }
@@ -1088,15 +1084,12 @@ e_book_client_get_capabilities_sync (EBookClient *client, GSList **capabilities,
  * all contacts in this @client. The call is finished by
  * e_book_client_get_required_fields_finish() from the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_book_client_get_required_fields (EBookClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	return e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_book_client_get_required_fields,
+	e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_book_client_get_required_fields,
 			e_gdbus_book_call_get_required_fields,
 			NULL, NULL, NULL, e_gdbus_book_call_get_required_fields_finish, NULL);
 }
@@ -1191,15 +1184,12 @@ e_book_client_get_required_fields_sync (EBookClient *client, GSList **fields, GC
  * in this @client. Other fields may be discarded. The call is finished by
  * e_book_client_get_supported_fields_finish() from the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_book_client_get_supported_fields (EBookClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	return e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_book_client_get_supported_fields,
+	e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_book_client_get_supported_fields,
 			e_gdbus_book_call_get_supported_fields,
 			NULL, NULL, NULL, e_gdbus_book_call_get_supported_fields_finish, NULL);
 }
@@ -1293,15 +1283,12 @@ e_book_client_get_supported_fields_sync (EBookClient *client, GSList **fields, G
  * The call is finished by e_book_client_get_supported_auth_methods_finish()
  * from the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_book_client_get_supported_auth_methods (EBookClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	return e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_book_client_get_supported_auth_methods,
+	e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_book_client_get_supported_auth_methods,
 			e_gdbus_book_call_get_supported_auth_methods,
 			NULL, NULL, NULL, e_gdbus_book_call_get_supported_auth_methods_finish, NULL);
 }
@@ -1392,30 +1379,24 @@ e_book_client_get_supported_auth_methods_sync (EBookClient *client, GSList **aut
  * The call is finished by e_book_client_add_contact_finish()
  * from the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_book_client_add_contact (EBookClient *client, const EContact *contact, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar *vcard, *gdbus_vcard = NULL;
 
-	g_return_val_if_fail (contact != NULL, 0);
-	g_return_val_if_fail (E_IS_CONTACT (contact), 0);
+	g_return_if_fail (contact != NULL);
+	g_return_if_fail (E_IS_CONTACT (contact));
 
 	vcard = e_vcard_to_string (E_VCARD (contact), EVC_FORMAT_VCARD_30);
 
-	opid = e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (vcard, &gdbus_vcard), cancellable, callback, user_data, e_book_client_add_contact,
+	e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (vcard, &gdbus_vcard), cancellable, callback, user_data, e_book_client_add_contact,
 			e_gdbus_book_call_add_contact,
 			NULL, NULL, e_gdbus_book_call_add_contact_finish, NULL, NULL);
 
 	g_free (vcard);
 	g_free (gdbus_vcard);
-
-	return opid;
 }
 
 /**
@@ -1518,30 +1499,24 @@ e_book_client_add_contact_sync (EBookClient *client, const EContact *contact, gc
  * The call is finished by e_book_client_modify_contact_finish()
  * from the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_book_client_modify_contact (EBookClient *client, const EContact *contact, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar *vcard, *gdbus_vcard = NULL;
 
-	g_return_val_if_fail (contact != NULL, 0);
-	g_return_val_if_fail (E_IS_CONTACT (contact), 0);
+	g_return_if_fail (contact != NULL);
+	g_return_if_fail (E_IS_CONTACT (contact));
 
 	vcard = e_vcard_to_string (E_VCARD (contact), EVC_FORMAT_VCARD_30);
 
-	opid = e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (vcard, &gdbus_vcard), cancellable, callback, user_data, e_book_client_modify_contact,
+	e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (vcard, &gdbus_vcard), cancellable, callback, user_data, e_book_client_modify_contact,
 			e_gdbus_book_call_modify_contact,
 			e_gdbus_book_call_modify_contact_finish, NULL, NULL, NULL, NULL);
 
 	g_free (vcard);
 	g_free (gdbus_vcard);
-
-	return opid;
 }
 
 /**
@@ -1612,34 +1587,28 @@ e_book_client_modify_contact_sync (EBookClient *client, const EContact *contact,
  * The call is finished by e_book_client_remove_contact_finish()
  * from the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_book_client_remove_contact (EBookClient *client, const EContact *contact, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar *uid;
 	const gchar *lst[2];
 
-	g_return_val_if_fail (contact != NULL, 0);
-	g_return_val_if_fail (E_IS_CONTACT (contact), 0);
+	g_return_if_fail (contact != NULL);
+	g_return_if_fail (E_IS_CONTACT (contact));
 
 	uid = e_util_utf8_make_valid (e_contact_get_const ((EContact *) contact, E_CONTACT_UID));
-	g_return_val_if_fail (uid != NULL, 0);
+	g_return_if_fail (uid != NULL);
 
 	lst[0] = uid;
 	lst[1] = NULL;
 
-	opid = e_client_proxy_call_strv (E_CLIENT (client), lst, cancellable, callback, user_data, e_book_client_remove_contact,
+	e_client_proxy_call_strv (E_CLIENT (client), lst, cancellable, callback, user_data, e_book_client_remove_contact,
 			e_gdbus_book_call_remove_contacts,
 			e_gdbus_book_call_remove_contacts_finish, NULL, NULL, NULL, NULL);
 
 	g_free (uid);
-
-	return opid;
 }
 
 /**
@@ -1716,33 +1685,27 @@ e_book_client_remove_contact_sync (EBookClient *client, const EContact *contact,
  * The call is finished by e_book_client_remove_contact_by_uid_finish()
  * from the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_book_client_remove_contact_by_uid (EBookClient *client, const gchar *uid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar *safe_uid;
 	const gchar *lst[2];
 
-	g_return_val_if_fail (uid != NULL, 0);
+	g_return_if_fail (uid != NULL);
 
 	safe_uid = e_util_utf8_make_valid (uid);
-	g_return_val_if_fail (safe_uid != NULL, 0);
+	g_return_if_fail (safe_uid != NULL);
 
 	lst[0] = safe_uid;
 	lst[1] = NULL;
 
-	opid = e_client_proxy_call_strv (E_CLIENT (client), lst, cancellable, callback, user_data, e_book_client_remove_contact_by_uid,
+	e_client_proxy_call_strv (E_CLIENT (client), lst, cancellable, callback, user_data, e_book_client_remove_contact_by_uid,
 			e_gdbus_book_call_remove_contacts,
 			e_gdbus_book_call_remove_contacts_finish, NULL, NULL, NULL, NULL);
 
 	g_free (safe_uid);
-
-	return opid;
 }
 
 /**
@@ -1821,29 +1784,23 @@ e_book_client_remove_contact_by_uid_sync (EBookClient *client, const gchar *uid,
  * The call is finished by e_book_client_remove_contacts_finish()
  * from the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_book_client_remove_contacts (EBookClient *client, const GSList *uids, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar **lst;
 
-	g_return_val_if_fail (uids != NULL, 0);
+	g_return_if_fail (uids != NULL);
 
 	lst = e_client_util_slist_to_strv (uids);
-	g_return_val_if_fail (lst != NULL, 0);
+	g_return_if_fail (lst != NULL);
 
-	opid = e_client_proxy_call_strv (E_CLIENT (client), (const gchar * const *) lst, cancellable, callback, user_data, e_book_client_remove_contacts,
+	e_client_proxy_call_strv (E_CLIENT (client), (const gchar * const *) lst, cancellable, callback, user_data, e_book_client_remove_contacts,
 			e_gdbus_book_call_remove_contacts,
 			e_gdbus_book_call_remove_contacts_finish, NULL, NULL, NULL, NULL);
 
 	g_strfreev (lst);
-
-	return opid;
 }
 
 /**
@@ -1918,29 +1875,23 @@ e_book_client_remove_contacts_sync (EBookClient *client, const GSList *uids, GCa
  * The call is finished by e_book_client_get_contact_finish()
  * from the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_book_client_get_contact (EBookClient *client, const gchar *uid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar *safe_uid;
 
-	g_return_val_if_fail (uid != NULL, 0);
+	g_return_if_fail (uid != NULL);
 
 	safe_uid = e_util_utf8_make_valid (uid);
-	g_return_val_if_fail (safe_uid != NULL, 0);
+	g_return_if_fail (safe_uid != NULL);
 	
-	opid = e_client_proxy_call_string (E_CLIENT (client), safe_uid, cancellable, callback, user_data, e_book_client_get_contact,
+	e_client_proxy_call_string (E_CLIENT (client), safe_uid, cancellable, callback, user_data, e_book_client_get_contact,
 			e_gdbus_book_call_get_contact,
 			NULL, NULL, e_gdbus_book_call_get_contact_finish, NULL, NULL);
 
 	g_free (safe_uid);
-
-	return opid;
 }
 
 /**
@@ -2039,29 +1990,23 @@ e_book_client_get_contact_sync (EBookClient *client, const gchar *uid, EContact
  * matched. The call is finished by e_book_client_get_contacts_finish()
  * from the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_book_client_get_contacts (EBookClient *client, const EBookQuery *query, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar *sexp, *gdbus_sexp = NULL;
 
-	g_return_val_if_fail (query != NULL, 0);
+	g_return_if_fail (query != NULL);
 
 	sexp = e_book_query_to_string ((EBookQuery *) query);
 
-	opid = e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (sexp, &gdbus_sexp), cancellable, callback, user_data, e_book_client_get_contacts,
+	e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (sexp, &gdbus_sexp), cancellable, callback, user_data, e_book_client_get_contacts,
 			e_gdbus_book_call_get_contact_list,
 			NULL, NULL, NULL, e_gdbus_book_call_get_contact_list_finish, NULL);
 
 	g_free (sexp);
 	g_free (gdbus_sexp);
-
-	return opid;
 }
 
 /**
@@ -2177,29 +2122,23 @@ e_book_client_get_contacts_sync (EBookClient *client, const EBookQuery *query, G
  * The call is finished by e_book_client_get_view_finish()
  * from the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_book_client_get_view (EBookClient *client, const EBookQuery *query, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar *sexp, *gdbus_sexp = NULL;
 
-	g_return_val_if_fail (query != NULL, 0);
+	g_return_if_fail (query != NULL);
 
 	sexp = e_book_query_to_string ((EBookQuery *) query);
 
-	opid = e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (sexp, &gdbus_sexp), cancellable, callback, user_data, e_book_client_get_view,
+	e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (sexp, &gdbus_sexp), cancellable, callback, user_data, e_book_client_get_view,
 			e_gdbus_book_call_get_view,
 			NULL, NULL, e_gdbus_book_call_get_view_finish, NULL, NULL);
 
 	g_free (sexp);
 	g_free (gdbus_sexp);
-
-	return opid;
 }
 
 static gboolean
diff --git a/addressbook/libebook/e-book-client.h b/addressbook/libebook/e-book-client.h
index 492d47a..7b5fd10 100644
--- a/addressbook/libebook/e-book-client.h
+++ b/addressbook/libebook/e-book-client.h
@@ -90,51 +90,51 @@ gboolean	e_book_client_set_self				(EBookClient *client, EContact *contact, GErr
 gboolean	e_book_client_is_self				(EContact *contact);
 
 /* Addressbook methods */
-guint32		e_book_client_get_capabilities			(EBookClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_book_client_get_capabilities			(EBookClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_book_client_get_capabilities_finish		(EBookClient *client, GAsyncResult *result, GSList **capabilities, GError **error);
 gboolean	e_book_client_get_capabilities_sync		(EBookClient *client, GSList **capabilities, GCancellable *cancellable, GError **error);
 
-guint32		e_book_client_get_required_fields		(EBookClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_book_client_get_required_fields		(EBookClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_book_client_get_required_fields_finish	(EBookClient *client, GAsyncResult *result, GSList **fields, GError **error);
 gboolean	e_book_client_get_required_fields_sync		(EBookClient *client, GSList **fields, GCancellable *cancellable, GError **error);
 
-guint32		e_book_client_get_supported_fields		(EBookClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_book_client_get_supported_fields		(EBookClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_book_client_get_supported_fields_finish	(EBookClient *client, GAsyncResult *result, GSList **fields, GError **error);
 gboolean	e_book_client_get_supported_fields_sync		(EBookClient *client, GSList **fields, GCancellable *cancellable, GError **error);
 
-guint32		e_book_client_get_supported_auth_methods	(EBookClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_book_client_get_supported_auth_methods	(EBookClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_book_client_get_supported_auth_methods_finish	(EBookClient *client, GAsyncResult *result, GSList **auth_methods, GError **error);
 gboolean	e_book_client_get_supported_auth_methods_sync	(EBookClient *client, GSList **auth_methods, GCancellable *cancellable, GError **error);
 
-guint32		e_book_client_add_contact			(EBookClient *client, const EContact *contact, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_book_client_add_contact			(EBookClient *client, const EContact *contact, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_book_client_add_contact_finish		(EBookClient *client, GAsyncResult *result, gchar **added_uid, GError **error);
 gboolean	e_book_client_add_contact_sync			(EBookClient *client, const EContact *contact, gchar **added_uid, GCancellable *cancellable, GError **error);
 
-guint32		e_book_client_modify_contact			(EBookClient *client, const EContact *contact, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_book_client_modify_contact			(EBookClient *client, const EContact *contact, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_book_client_modify_contact_finish		(EBookClient *client, GAsyncResult *result, GError **error);
 gboolean	e_book_client_modify_contact_sync		(EBookClient *client, const EContact *contact, GCancellable *cancellable, GError **error);
 
-guint32		e_book_client_remove_contact			(EBookClient *client, const EContact *contact, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_book_client_remove_contact			(EBookClient *client, const EContact *contact, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_book_client_remove_contact_finish		(EBookClient *client, GAsyncResult *result, GError **error);
 gboolean	e_book_client_remove_contact_sync		(EBookClient *client, const EContact *contact, GCancellable *cancellable, GError **error);
 
-guint32		e_book_client_remove_contact_by_uid		(EBookClient *client, const gchar *uid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_book_client_remove_contact_by_uid		(EBookClient *client, const gchar *uid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_book_client_remove_contact_by_uid_finish	(EBookClient *client, GAsyncResult *result, GError **error);
 gboolean	e_book_client_remove_contact_by_uid_sync	(EBookClient *client, const gchar *uid, GCancellable *cancellable, GError **error);
 
-guint32		e_book_client_remove_contacts			(EBookClient *client, const GSList *uids, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_book_client_remove_contacts			(EBookClient *client, const GSList *uids, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_book_client_remove_contacts_finish		(EBookClient *client, GAsyncResult *result, GError **error);
 gboolean	e_book_client_remove_contacts_sync		(EBookClient *client, const GSList *uids, GCancellable *cancellable, GError **error);
 
-guint32		e_book_client_get_contact			(EBookClient *client, const gchar *uid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_book_client_get_contact			(EBookClient *client, const gchar *uid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_book_client_get_contact_finish		(EBookClient *client, GAsyncResult *result, EContact **contact, GError **error);
 gboolean	e_book_client_get_contact_sync			(EBookClient *client, const gchar *uid, EContact **contact, GCancellable *cancellable, GError **error);
 
-guint32		e_book_client_get_contacts			(EBookClient *client, const EBookQuery *query, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_book_client_get_contacts			(EBookClient *client, const EBookQuery *query, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_book_client_get_contacts_finish		(EBookClient *client, GAsyncResult *result, GSList **contacts, GError **error);
 gboolean	e_book_client_get_contacts_sync			(EBookClient *client, const EBookQuery *query, GSList **contacts, GCancellable *cancellable, GError **error);
 
-guint32		e_book_client_get_view				(EBookClient *client, const EBookQuery *query, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_book_client_get_view				(EBookClient *client, const EBookQuery *query, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_book_client_get_view_finish			(EBookClient *client, GAsyncResult *result, EBookView **book_view, GError **error);
 gboolean	e_book_client_get_view_sync			(EBookClient *client, const EBookQuery *query, EBookView **book_view, GCancellable *cancellable, GError **error);
 
diff --git a/calendar/libecal/e-cal-client.c b/calendar/libecal/e-cal-client.c
index 5c5ae26..b7a4e9a 100644
--- a/calendar/libecal/e-cal-client.c
+++ b/calendar/libecal/e-cal-client.c
@@ -164,7 +164,6 @@ get_client_error_from_gerror (GError *error, GError **client_error)
 	#undef err
 
 	g_return_if_fail (client_error != NULL);
-	g_return_if_fail (*client_error == NULL);
 
 	if G_LIKELY (error == NULL)
 		return;
@@ -1781,10 +1780,10 @@ e_cal_client_get_component_as_string (ECalClient *client, icalcomponent *icalcom
 	return obj_string;
 }
 
-static guint32
+static void
 cal_client_open (EClient *client, gboolean only_if_exists, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	return e_client_proxy_call_boolean (client, only_if_exists, cancellable, callback, user_data, cal_client_open,
+	e_client_proxy_call_boolean (client, only_if_exists, cancellable, callback, user_data, cal_client_open,
 			e_gdbus_cal_call_open,
 			e_gdbus_cal_call_open_finish, NULL, NULL, NULL, NULL);
 }
@@ -1815,10 +1814,10 @@ cal_client_open_sync (EClient *client, gboolean only_if_exists, GCancellable *ca
 	return e_client_proxy_call_sync_boolean__void (client, only_if_exists, cancellable, error, e_gdbus_cal_call_open_sync);
 }
 
-static guint32
+static void
 cal_client_remove (EClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	return e_client_proxy_call_void (client, cancellable, callback, user_data, cal_client_remove,
+	e_client_proxy_call_void (client, cancellable, callback, user_data, cal_client_remove,
 			e_gdbus_cal_call_remove,
 			e_gdbus_cal_call_remove_finish, NULL, NULL, NULL, NULL);
 }
@@ -1861,18 +1860,15 @@ cal_client_remove_sync (EClient *client, GCancellable *cancellable, GError **err
  * supports. The call is finished by e_cal_client_get_capabilities_finish() from
  * the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Note: Usually is sufficient to use e_client_get_capabilities() or e_client_check_capability(),
  * which caches capabilities of a backend on the client side.
  *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_get_capabilities (ECalClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	return e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_cal_client_get_capabilities,
+	e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_cal_client_get_capabilities,
 			e_gdbus_cal_call_get_capabilities,
 			NULL, NULL, e_gdbus_cal_call_get_capabilities_finish, NULL, NULL);
 }
@@ -1994,15 +1990,12 @@ complete_string_exchange (gboolean res, gchar *out_string, gchar **result, GErro
  * The call is finished by e_cal_client_get_cal_email_address_finish() from
  * the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_get_cal_email_address (ECalClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	return e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_cal_client_get_cal_email_address,
+	e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_cal_client_get_cal_email_address,
 			e_gdbus_cal_call_get_cal_email_address,
 			NULL, NULL, e_gdbus_cal_call_get_cal_email_address_finish, NULL, NULL);
 }
@@ -2081,15 +2074,12 @@ e_cal_client_get_cal_email_address_sync (ECalClient *client, gchar **address, GC
  * The call is finished by e_cal_client_get_alarm_email_address_finish() from
  * the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_get_alarm_email_address (ECalClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	return e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_cal_client_get_alarm_email_address,
+	e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_cal_client_get_alarm_email_address,
 			e_gdbus_cal_call_get_alarm_email_address,
 			NULL, NULL, e_gdbus_cal_call_get_alarm_email_address_finish, NULL, NULL);
 }
@@ -2168,15 +2158,12 @@ e_cal_client_get_alarm_email_address_sync (ECalClient *client, gchar **address,
  * values for properties needed. The call is finished
  * by e_cal_client_get_default_object_finish() from the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_get_default_object (ECalClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	return e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_cal_client_get_default_object,
+	e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_cal_client_get_default_object,
 			e_gdbus_cal_call_get_default_object,
 			NULL, NULL, e_gdbus_cal_call_get_default_object_finish, NULL, NULL);
 }
@@ -2278,15 +2265,12 @@ e_cal_client_get_default_object_sync (ECalClient *client, icalcomponent **icalco
  * The call is finished by e_cal_client_refresh_finish() from
  * the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_refresh (ECalClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	return e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_cal_client_refresh,
+	e_client_proxy_call_void (E_CLIENT (client), cancellable, callback, user_data, e_cal_client_refresh,
 			e_gdbus_cal_call_refresh,
 			e_gdbus_cal_call_refresh_finish, NULL, NULL, NULL, NULL);
 }
@@ -2349,28 +2333,22 @@ e_cal_client_refresh_sync (ECalClient *client, GCancellable *cancellable, GError
  * identifier. The call is finished by e_cal_client_get_object_finish()
  * from the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_get_object (ECalClient *client, const gchar *uid, const gchar *rid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar **strv;
 
-	g_return_val_if_fail (uid != NULL, 0);
+	g_return_if_fail (uid != NULL);
 
 	strv = e_gdbus_cal_encode_get_object (uid, rid);
 
-	opid = e_client_proxy_call_strv (E_CLIENT (client), (const gchar * const *) strv, cancellable, callback, user_data, e_cal_client_get_object,
+	e_client_proxy_call_strv (E_CLIENT (client), (const gchar * const *) strv, cancellable, callback, user_data, e_cal_client_get_object,
 			e_gdbus_cal_call_get_object,
 			NULL, NULL, e_gdbus_cal_call_get_object_finish, NULL, NULL);
 
 	g_strfreev (strv);
-
-	return opid;
 }
 
 /**
@@ -2456,28 +2434,22 @@ e_cal_client_get_object_sync (ECalClient *client, const gchar *uid, const gchar
  * The call is finished by e_cal_client_get_objects_for_uid_finish() from
  * the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_get_objects_for_uid (ECalClient *client, const gchar *uid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar **strv;
 
-	g_return_val_if_fail (uid != NULL, 0);
+	g_return_if_fail (uid != NULL);
 
 	strv = e_gdbus_cal_encode_get_object (uid, "");
 
-	opid = e_client_proxy_call_strv (E_CLIENT (client), (const gchar * const *) strv, cancellable, callback, user_data, e_cal_client_get_objects_for_uid,
+	e_client_proxy_call_strv (E_CLIENT (client), (const gchar * const *) strv, cancellable, callback, user_data, e_cal_client_get_objects_for_uid,
 			e_gdbus_cal_call_get_object,
 			NULL, NULL, e_gdbus_cal_call_get_object_finish, NULL, NULL);
 
 	g_strfreev (strv);
-
-	return opid;
 }
 
 static gboolean
@@ -2615,26 +2587,20 @@ e_cal_client_get_objects_for_uid_sync (ECalClient *client, const gchar *uid, GSL
  * The call is finished by e_cal_client_get_object_list_finish() from
  * the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_get_object_list (ECalClient *client, const gchar *sexp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
 	gchar *gdbus_sexp = NULL;
-	guint32 opid;
 
-	g_return_val_if_fail (sexp != NULL, 0);
+	g_return_if_fail (sexp != NULL);
 
-	opid = e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (sexp, &gdbus_sexp), cancellable, callback, user_data, e_cal_client_get_object_list,
+	e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (sexp, &gdbus_sexp), cancellable, callback, user_data, e_cal_client_get_object_list,
 			e_gdbus_cal_call_get_object_list,
 			NULL, NULL, NULL, e_gdbus_cal_call_get_object_list_finish, NULL);
 
 	g_free (gdbus_sexp);
-
-	return opid;
 }
 
 static gboolean
@@ -2748,26 +2714,20 @@ e_cal_client_get_object_list_sync (ECalClient *client, const gchar *sexp, GSList
  * The call is finished by e_cal_client_get_object_list_as_comps_finish() from
  * the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_get_object_list_as_comps (ECalClient *client, const gchar *sexp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar *gdbus_sexp = NULL;
 
-	g_return_val_if_fail (sexp != NULL, 0);
+	g_return_if_fail (sexp != NULL);
 
-	opid = e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (sexp, &gdbus_sexp), cancellable, callback, user_data, e_cal_client_get_object_list_as_comps,
+	e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (sexp, &gdbus_sexp), cancellable, callback, user_data, e_cal_client_get_object_list_as_comps,
 			e_gdbus_cal_call_get_object_list,
 			NULL, NULL, NULL, e_gdbus_cal_call_get_object_list_finish, NULL);
 
 	g_free (gdbus_sexp);
-
-	return opid;
 }
 
 static gboolean
@@ -2889,30 +2849,24 @@ e_cal_client_get_object_list_as_comps_sync (ECalClient *client, const gchar *sex
  * The call is finished by e_cal_client_get_free_busy_finish() from
  * the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_get_free_busy (ECalClient *client, time_t start, time_t end, const GSList *users, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
 	gchar **strv;
-	guint32 opid;
 
-	g_return_val_if_fail (start > 0, 0);
-	g_return_val_if_fail (end > 0, 0);
-	g_return_val_if_fail (users != NULL, 0);
+	g_return_if_fail (start > 0);
+	g_return_if_fail (end > 0);
+	g_return_if_fail (users != NULL);
 
 	strv = e_gdbus_cal_encode_get_free_busy (start, end, users);
 
-	opid = e_client_proxy_call_strv (E_CLIENT (client), (const gchar * const *) strv, cancellable, callback, user_data, e_cal_client_get_free_busy,
+	e_client_proxy_call_strv (E_CLIENT (client), (const gchar * const *) strv, cancellable, callback, user_data, e_cal_client_get_free_busy,
 			e_gdbus_cal_call_get_free_busy,
 			e_gdbus_cal_call_get_free_busy_finish, NULL, NULL, NULL, NULL);
 
 	g_strfreev (strv);
-
-	return opid;
 }
 
 /**
@@ -2987,29 +2941,23 @@ e_cal_client_get_free_busy_sync (ECalClient *client, time_t start, time_t end, c
  * The call is finished by e_cal_client_create_object_finish() from
  * the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_create_object (ECalClient *client, const icalcomponent *icalcomp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar *comp_str, *gdbus_comp = NULL;
 
-	g_return_val_if_fail (icalcomp != NULL, 0);
+	g_return_if_fail (icalcomp != NULL);
 
 	comp_str = icalcomponent_as_ical_string_r ((icalcomponent *) icalcomp);
 
-	opid = e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (comp_str, &gdbus_comp), cancellable, callback, user_data, e_cal_client_create_object,
+	e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (comp_str, &gdbus_comp), cancellable, callback, user_data, e_cal_client_create_object,
 			e_gdbus_cal_call_create_object,
 			NULL, NULL, e_gdbus_cal_call_create_object_finish, NULL, NULL);
 
 	g_free (comp_str);
 	g_free (gdbus_comp);
-
-	return opid;
 }
 
 /**
@@ -3106,30 +3054,24 @@ e_cal_client_create_object_sync (ECalClient *client, const icalcomponent *icalco
  * The call is finished by e_cal_client_modify_object_finish() from
  * the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_modify_object (ECalClient *client, const icalcomponent *icalcomp, CalObjModType mod, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar *comp_str, **strv;
 
-	g_return_val_if_fail (icalcomp != NULL, 0);
+	g_return_if_fail (icalcomp != NULL);
 
 	comp_str = icalcomponent_as_ical_string_r ((icalcomponent *) icalcomp);
 	strv = e_gdbus_cal_encode_modify_object (comp_str, mod);
 
-	opid = e_client_proxy_call_strv (E_CLIENT (client), (const gchar * const *) strv, cancellable, callback, user_data, e_cal_client_modify_object,
+	e_client_proxy_call_strv (E_CLIENT (client), (const gchar * const *) strv, cancellable, callback, user_data, e_cal_client_modify_object,
 			e_gdbus_cal_call_modify_object,
 			e_gdbus_cal_call_modify_object_finish, NULL, NULL, NULL, NULL);
 
 	g_strfreev (strv);
 	g_free (comp_str);
-
-	return opid;
 }
 
 /**
@@ -3216,28 +3158,22 @@ e_cal_client_modify_object_sync (ECalClient *client, const icalcomponent *icalco
  * The call is finished by e_cal_client_remove_object_finish() from
  * the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_remove_object (ECalClient *client, const gchar *uid, const gchar *rid, CalObjModType mod, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar **strv;
 
-	g_return_val_if_fail (uid != NULL, 0);
+	g_return_if_fail (uid != NULL);
 
 	strv = e_gdbus_cal_encode_remove_object (uid, rid, mod);
 
-	opid = e_client_proxy_call_strv (E_CLIENT (client), (const gchar * const *) strv, cancellable, callback, user_data, e_cal_client_remove_object,
+	e_client_proxy_call_strv (E_CLIENT (client), (const gchar * const *) strv, cancellable, callback, user_data, e_cal_client_remove_object,
 			e_gdbus_cal_call_remove_object,
 			e_gdbus_cal_call_remove_object_finish, NULL, NULL, NULL, NULL);
 
 	g_strfreev (strv);
-
-	return opid;
 }
 
 /**
@@ -3317,29 +3253,23 @@ e_cal_client_remove_object_sync (ECalClient *client, const gchar *uid, const gch
  * The call is finished by e_cal_client_receive_objects_finish() from
  * the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_receive_objects (ECalClient *client, const icalcomponent *icalcomp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar *comp_str, *gdbus_comp = NULL;
 
-	g_return_val_if_fail (icalcomp != NULL, 0);
+	g_return_if_fail (icalcomp != NULL);
 
 	comp_str = icalcomponent_as_ical_string_r ((icalcomponent *) icalcomp);
 
-	opid = e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (comp_str, &gdbus_comp), cancellable, callback, user_data, e_cal_client_receive_objects,
+	e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (comp_str, &gdbus_comp), cancellable, callback, user_data, e_cal_client_receive_objects,
 			e_gdbus_cal_call_receive_objects,
 			e_gdbus_cal_call_receive_objects_finish, NULL, NULL, NULL, NULL);
 
 	g_free (comp_str);
 	g_free (gdbus_comp);
-
-	return opid;
 }
 
 /**
@@ -3413,29 +3343,23 @@ e_cal_client_receive_objects_sync (ECalClient *client, const icalcomponent *ical
  * The call is finished by e_cal_client_send_objects_finish() from
  * the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_send_objects (ECalClient *client, const icalcomponent *icalcomp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar *comp_str, *gdbus_comp = NULL;
 
-	g_return_val_if_fail (icalcomp != NULL, 0);
+	g_return_if_fail (icalcomp != NULL);
 
 	comp_str = icalcomponent_as_ical_string_r ((icalcomponent *) icalcomp);
 
-	opid = e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (comp_str, &gdbus_comp), cancellable, callback, user_data, e_cal_client_send_objects,
+	e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (comp_str, &gdbus_comp), cancellable, callback, user_data, e_cal_client_send_objects,
 			e_gdbus_cal_call_send_objects,
 			NULL, NULL, NULL, e_gdbus_cal_call_send_objects_finish, NULL);
 
 	g_free (comp_str);
 	g_free (gdbus_comp);
-
-	return opid;
 }
 
 static gboolean
@@ -3565,28 +3489,22 @@ e_cal_client_send_objects_sync (ECalClient *client, const icalcomponent *icalcom
  * The call is finished by e_cal_client_get_attachment_uris_finish() from
  * the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_get_attachment_uris (ECalClient *client, const gchar *uid, const gchar *rid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar **strv;
 
-	g_return_val_if_fail (uid != NULL, 0);
+	g_return_if_fail (uid != NULL);
 
 	strv = e_gdbus_cal_encode_get_attachment_uris (uid, rid);
 
-	opid = e_client_proxy_call_strv (E_CLIENT (client), (const gchar * const *) strv, cancellable, callback, user_data, e_cal_client_get_attachment_uris,
+	e_client_proxy_call_strv (E_CLIENT (client), (const gchar * const *) strv, cancellable, callback, user_data, e_cal_client_get_attachment_uris,
 			e_gdbus_cal_call_get_attachment_uris,
 			NULL, NULL, NULL, e_gdbus_cal_call_get_attachment_uris_finish, NULL);
 
 	g_strfreev (strv);
-
-	return opid;
 }
 
 /**
@@ -3687,26 +3605,20 @@ e_cal_client_get_attachment_uris_sync (ECalClient *client, const gchar *uid, con
  * The call is finished by e_cal_client_get_view_finish()
  * from the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_get_view (ECalClient *client, const gchar *sexp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar *gdbus_sexp = NULL;
 
-	g_return_val_if_fail (sexp != NULL, 0);
+	g_return_if_fail (sexp != NULL);
 
-	opid = e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (sexp, &gdbus_sexp), cancellable, callback, user_data, e_cal_client_get_view,
+	e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (sexp, &gdbus_sexp), cancellable, callback, user_data, e_cal_client_get_view,
 			e_gdbus_cal_call_get_view,
 			NULL, NULL, e_gdbus_cal_call_get_view_finish, NULL, NULL);
 
 	g_free (gdbus_sexp);
-
-	return opid;
 }
 
 static gboolean
@@ -3929,23 +3841,20 @@ cal_client_get_timezone_from_cache_finish (ECalClient *client, GAsyncResult *res
  * The call is finished by e_cal_client_get_timezone_finish() from
  * the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_get_timezone (ECalClient *client, const gchar *tzid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	gchar *gdbus_tzid = NULL;
 	icaltimezone *zone;
 
-	g_return_val_if_fail (tzid != NULL, 0);
+	g_return_if_fail (tzid != NULL);
 
 	zone = cal_client_get_timezone_from_cache (client, tzid);
 	if (zone) {
 		GCancellable *use_cancellable = cancellable;
+		guint32 opid;
 
 		if (!use_cancellable)
 			use_cancellable = g_cancellable_new ();
@@ -3963,14 +3872,12 @@ e_cal_client_get_timezone (ECalClient *client, const gchar *tzid, GCancellable *
 		if (use_cancellable != cancellable)
 			g_object_unref (use_cancellable);
 	} else {
-		opid = e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (tzid, &gdbus_tzid), cancellable, callback, user_data, e_cal_client_get_timezone,
+		e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (tzid, &gdbus_tzid), cancellable, callback, user_data, e_cal_client_get_timezone,
 				e_gdbus_cal_call_get_timezone,
 				NULL, NULL, e_gdbus_cal_call_get_timezone_finish, NULL, NULL);
 
 		g_free (gdbus_tzid);
 	}
-
-	return opid;
 }
 
 static gboolean
@@ -4097,36 +4004,30 @@ e_cal_client_get_timezone_sync (ECalClient *client, const gchar *tzid, icaltimez
  * The call is finished by e_cal_client_add_timezone_finish() from
  * the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_cal_client_add_timezone (ECalClient *client, const icaltimezone *zone, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
-	guint32 opid;
 	icalcomponent *icalcomp;
 	gchar *zone_str, *gdbus_zone = NULL;
 
-	g_return_val_if_fail (zone != NULL, 0);
+	g_return_if_fail (zone != NULL);
 
 	if (zone == icaltimezone_get_utc_timezone ())
-		return 0;
+		return;
 
 	icalcomp = icaltimezone_get_component ((icaltimezone *) zone);
-	g_return_val_if_fail (icalcomp != NULL, 0);
+	g_return_if_fail (icalcomp != NULL);
 
 	zone_str = icalcomponent_as_ical_string_r (icalcomp);
 
-	opid = e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (zone_str, &gdbus_zone), cancellable, callback, user_data, e_cal_client_add_timezone,
+	e_client_proxy_call_string (E_CLIENT (client), e_util_ensure_gdbus_string (zone_str, &gdbus_zone), cancellable, callback, user_data, e_cal_client_add_timezone,
 			e_gdbus_cal_call_add_timezone,
 			e_gdbus_cal_call_add_timezone_finish, NULL, NULL, NULL, NULL);
 
 	g_free (zone_str);
 	g_free (gdbus_zone);
-
-	return opid;
 }
 
 /**
diff --git a/calendar/libecal/e-cal-client.h b/calendar/libecal/e-cal-client.h
index 2adeae9..d348ed6 100644
--- a/calendar/libecal/e-cal-client.h
+++ b/calendar/libecal/e-cal-client.h
@@ -117,79 +117,79 @@ void		e_cal_client_generate_instances_for_object	(ECalClient *client, icalcompon
 gchar *		e_cal_client_get_component_as_string		(ECalClient *client, icalcomponent *icalcomp);
 
 /* Calendar methods */
-guint32		e_cal_client_get_capabilities			(ECalClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_get_capabilities			(ECalClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_get_capabilities_finish		(ECalClient *client, GAsyncResult *result, GSList **capabilities, GError **error);
 gboolean	e_cal_client_get_capabilities_sync		(ECalClient *client, GSList **capabilities, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_get_cal_email_address		(ECalClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_get_cal_email_address		(ECalClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_get_cal_email_address_finish	(ECalClient *client, GAsyncResult *result, gchar **address, GError **error);
 gboolean	e_cal_client_get_cal_email_address_sync		(ECalClient *client, gchar **address, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_get_alarm_email_address		(ECalClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_get_alarm_email_address		(ECalClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_get_alarm_email_address_finish	(ECalClient *client, GAsyncResult *result, gchar **address, GError **error);
 gboolean	e_cal_client_get_alarm_email_address_sync	(ECalClient *client, gchar **address, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_get_default_object			(ECalClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_get_default_object			(ECalClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_get_default_object_finish		(ECalClient *client, GAsyncResult *result, icalcomponent **icalcomp, GError **error);
 gboolean	e_cal_client_get_default_object_sync		(ECalClient *client, icalcomponent **icalcomp, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_refresh				(ECalClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_refresh				(ECalClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_refresh_finish			(ECalClient *client, GAsyncResult *result, GError **error);
 gboolean	e_cal_client_refresh_sync			(ECalClient *client, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_get_object				(ECalClient *client, const gchar *uid, const gchar *rid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_get_object				(ECalClient *client, const gchar *uid, const gchar *rid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_get_object_finish			(ECalClient *client, GAsyncResult *result, icalcomponent **icalcomp, GError **error);
 gboolean	e_cal_client_get_object_sync			(ECalClient *client, const gchar *uid, const gchar *rid, icalcomponent **icalcomp, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_get_objects_for_uid		(ECalClient *client, const gchar *uid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_get_objects_for_uid		(ECalClient *client, const gchar *uid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_get_objects_for_uid_finish		(ECalClient *client, GAsyncResult *result, GSList **ecalcomps, GError **error);
 gboolean	e_cal_client_get_objects_for_uid_sync		(ECalClient *client, const gchar *uid, GSList **ecalcomps, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_get_object_list			(ECalClient *client, const gchar *sexp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_get_object_list			(ECalClient *client, const gchar *sexp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_get_object_list_finish		(ECalClient *client, GAsyncResult *result, GSList **icalcomps, GError **error);
 gboolean	e_cal_client_get_object_list_sync		(ECalClient *client, const gchar *sexp, GSList **icalcomps, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_get_object_list_as_comps		(ECalClient *client, const gchar *sexp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_get_object_list_as_comps		(ECalClient *client, const gchar *sexp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_get_object_list_as_comps_finish	(ECalClient *client, GAsyncResult *result, GSList **ecalcomps, GError **error);
 gboolean	e_cal_client_get_object_list_as_comps_sync	(ECalClient *client, const gchar *sexp, GSList **ecalcomps, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_get_free_busy			(ECalClient *client, time_t start, time_t end, const GSList *users, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_get_free_busy			(ECalClient *client, time_t start, time_t end, const GSList *users, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_get_free_busy_finish		(ECalClient *client, GAsyncResult *result, GError **error);
 gboolean	e_cal_client_get_free_busy_sync			(ECalClient *client, time_t start, time_t end, const GSList *users, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_create_object			(ECalClient *client, const icalcomponent *icalcomp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_create_object			(ECalClient *client, const icalcomponent *icalcomp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_create_object_finish		(ECalClient *client, GAsyncResult *result, gchar **uid, GError **error);
 gboolean	e_cal_client_create_object_sync			(ECalClient *client, const icalcomponent *icalcomp, gchar **uid, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_modify_object			(ECalClient *client, const icalcomponent *icalcomp, CalObjModType mod, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_modify_object			(ECalClient *client, const icalcomponent *icalcomp, CalObjModType mod, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_modify_object_finish		(ECalClient *client, GAsyncResult *result, GError **error);
 gboolean	e_cal_client_modify_object_sync			(ECalClient *client, const icalcomponent *icalcomp, CalObjModType mod, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_remove_object			(ECalClient *client, const gchar *uid, const gchar *rid, CalObjModType mod, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_remove_object			(ECalClient *client, const gchar *uid, const gchar *rid, CalObjModType mod, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_remove_object_finish		(ECalClient *client, GAsyncResult *result, GError **error);
 gboolean	e_cal_client_remove_object_sync			(ECalClient *client, const gchar *uid, const gchar *rid, CalObjModType mod, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_receive_objects			(ECalClient *client, const icalcomponent *icalcomp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_receive_objects			(ECalClient *client, const icalcomponent *icalcomp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_receive_objects_finish		(ECalClient *client, GAsyncResult *result, GError **error);
 gboolean	e_cal_client_receive_objects_sync		(ECalClient *client, const icalcomponent *icalcomp, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_send_objects			(ECalClient *client, const icalcomponent *icalcomp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_send_objects			(ECalClient *client, const icalcomponent *icalcomp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_send_objects_finish		(ECalClient *client, GAsyncResult *result, GSList **users, icalcomponent **modified_icalcomp, GError **error);
 gboolean	e_cal_client_send_objects_sync			(ECalClient *client, const icalcomponent *icalcomp, GSList **users, icalcomponent **modified_icalcomp, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_get_attachment_uris		(ECalClient *client, const gchar *uid, const gchar *rid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_get_attachment_uris		(ECalClient *client, const gchar *uid, const gchar *rid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_get_attachment_uris_finish		(ECalClient *client, GAsyncResult *result, GSList **attachment_uris, GError **error);
 gboolean	e_cal_client_get_attachment_uris_sync		(ECalClient *client, const gchar *uid, const gchar *rid, GSList **attachment_uris, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_get_view				(ECalClient *client, const gchar *sexp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_get_view				(ECalClient *client, const gchar *sexp, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_get_view_finish			(ECalClient *client, GAsyncResult *result, ECalView **view, GError **error);
 gboolean	e_cal_client_get_view_sync			(ECalClient *client, const gchar *sexp, ECalView **view, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_get_timezone			(ECalClient *client, const gchar *tzid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_get_timezone			(ECalClient *client, const gchar *tzid, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_get_timezone_finish		(ECalClient *client, GAsyncResult *result, icaltimezone **zone, GError **error);
 gboolean	e_cal_client_get_timezone_sync			(ECalClient *client, const gchar *tzid, icaltimezone **zone, GCancellable *cancellable, GError **error);
 
-guint32		e_cal_client_add_timezone			(ECalClient *client, const icaltimezone *zone, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_cal_client_add_timezone			(ECalClient *client, const icaltimezone *zone, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_cal_client_add_timezone_finish		(ECalClient *client, GAsyncResult *result, GError **error);
 gboolean	e_cal_client_add_timezone_sync			(ECalClient *client, const icaltimezone *zone, GCancellable *cancellable, GError **error);
 
diff --git a/libedataserver/e-client.c b/libedataserver/e-client.c
index a8018a6..39a0ae3 100644
--- a/libedataserver/e-client.c
+++ b/libedataserver/e-client.c
@@ -642,8 +642,8 @@ e_client_is_opened (EClient *client)
 	return client->priv->opened;
 }
 
-/**
- * e_client_cancel_op:
+/*
+ * client_cancel_op:
  * @client: an #EClient
  * @opid: asynchronous operation ID
  *
@@ -652,9 +652,9 @@ e_client_is_opened (EClient *client)
  * if the asynchronous operation doesn't exist any more.
  *
  * Since: 3.2
- **/
-void
-e_client_cancel_op (EClient *client, guint32 opid)
+ */
+static void
+client_cancel_op (EClient *client, guint32 opid)
 {
 	GCancellable *cancellable;
 
@@ -685,7 +685,7 @@ gather_opids_cb (gpointer opid, gpointer cancellable, gpointer ids_list)
 static void
 cancel_op_cb (gpointer opid, gpointer client)
 {
-	e_client_cancel_op (client, GPOINTER_TO_INT (opid));
+	client_cancel_op (client, GPOINTER_TO_INT (opid));
 }
 
 /**
@@ -843,26 +843,23 @@ e_client_emit_backend_died (EClient *client)
  * Opens the @client, making it ready for queries and other operations.
  * The call is finished by e_client_open_finish() from the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_client_open (EClient *client, gboolean only_if_exists, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
 	EClientClass *klass;
 
-	g_return_val_if_fail (client != NULL, 0);
-	g_return_val_if_fail (E_IS_CLIENT (client), 0);
-	g_return_val_if_fail (client->priv != NULL, 0);
-	g_return_val_if_fail (callback != NULL, 0);
+	g_return_if_fail (callback != NULL);
+	g_return_if_fail (client != NULL);
+	g_return_if_fail (E_IS_CLIENT (client));
+	g_return_if_fail (client->priv != NULL);
 
 	klass = E_CLIENT_GET_CLASS (client);
-	g_return_val_if_fail (klass != NULL, 0);
-	g_return_val_if_fail (klass->open != NULL, 0);
+	g_return_if_fail (klass != NULL);
+	g_return_if_fail (klass->open != NULL);
 
-	return klass->open (client, only_if_exists, cancellable, callback, user_data);
+	klass->open (client, only_if_exists, cancellable, callback, user_data);
 }
 
 /**
@@ -939,26 +936,23 @@ e_client_open_sync (EClient *client, gboolean only_if_exists, GCancellable *canc
  * deletes the database file. You cannot get it back!
  * The call is finished by e_client_remove_finish() from the @callback.
  *
- * Returns: Asynchronous operation ID, which can be passed to e_client_cancel_op(),
- * or zero on a failure.
- *
  * Since: 3.2
  **/
-guint32
+void
 e_client_remove (EClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data)
 {
 	EClientClass *klass;
 
-	g_return_val_if_fail (client != NULL, 0);
-	g_return_val_if_fail (E_IS_CLIENT (client), 0);
-	g_return_val_if_fail (client->priv != NULL, 0);
-	g_return_val_if_fail (callback != NULL, 0);
+	g_return_if_fail (client != NULL);
+	g_return_if_fail (E_IS_CLIENT (client));
+	g_return_if_fail (client->priv != NULL);
+	g_return_if_fail (callback != NULL);
 
 	klass = E_CLIENT_GET_CLASS (client);
-	g_return_val_if_fail (klass != NULL, 0);
-	g_return_val_if_fail (klass->remove != NULL, 0);
+	g_return_if_fail (klass != NULL);
+	g_return_if_fail (klass->remove != NULL);
 
-	return klass->remove (client, cancellable, callback, user_data);
+	klass->remove (client, cancellable, callback, user_data);
 }
 
 /**
@@ -1532,66 +1526,69 @@ async_result_ready_cb (GObject *source_object, GAsyncResult *result, gpointer us
 }
 
 static EClientAsyncOpData *
-prepare_async_data (EClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag, EClientProxyFinishVoidFunc finish_void, EClientProxyFinishBooleanFunc finish_boolean, EClientProxyFinishStringFunc finish_string, EClientProxyFinishStrvFunc finish_strv, EClientProxyFinishUintFunc finish_uint, GDBusProxy **proxy, guint32 *opid, GCancellable **out_cancellable)
+prepare_async_data (EClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag, gboolean error_report_only, EClientProxyFinishVoidFunc finish_void, EClientProxyFinishBooleanFunc finish_boolean, EClientProxyFinishStringFunc finish_string, EClientProxyFinishStrvFunc finish_strv, EClientProxyFinishUintFunc finish_uint, GDBusProxy **proxy, GCancellable **out_cancellable)
 {
 	EClientAsyncOpData *async_data;
 	GCancellable *use_cancellable;
+	guint32 opid;
 
 	g_return_val_if_fail (client != NULL, NULL);
 	g_return_val_if_fail (callback != NULL, NULL);
 	g_return_val_if_fail (source_tag != NULL, NULL);
-	g_return_val_if_fail (proxy != NULL, NULL);
-	g_return_val_if_fail (opid != NULL, NULL);
-	g_return_val_if_fail (out_cancellable != NULL, NULL);
-	g_return_val_if_fail (finish_void || finish_boolean || finish_string || finish_strv || finish_uint, NULL);
-
-	if (finish_void) {
-		g_return_val_if_fail (finish_boolean == NULL, NULL);
-		g_return_val_if_fail (finish_string == NULL, NULL);
-		g_return_val_if_fail (finish_strv == NULL, NULL);
-		g_return_val_if_fail (finish_uint == NULL, NULL);
-	}
 
-	if (finish_boolean) {
-		g_return_val_if_fail (finish_void == NULL, NULL);
-		g_return_val_if_fail (finish_string == NULL, NULL);
-		g_return_val_if_fail (finish_strv == NULL, NULL);
-		g_return_val_if_fail (finish_uint == NULL, NULL);
-	}
+	if (!error_report_only) {
+		g_return_val_if_fail (proxy != NULL, NULL);
+		g_return_val_if_fail (out_cancellable != NULL, NULL);
+		g_return_val_if_fail (finish_void || finish_boolean || finish_string || finish_strv || finish_uint, NULL);
 
-	if (finish_string) {
-		g_return_val_if_fail (finish_void == NULL, NULL);
-		g_return_val_if_fail (finish_boolean == NULL, NULL);
-		g_return_val_if_fail (finish_strv == NULL, NULL);
-		g_return_val_if_fail (finish_uint == NULL, NULL);
-	}
+		if (finish_void) {
+			g_return_val_if_fail (finish_boolean == NULL, NULL);
+			g_return_val_if_fail (finish_string == NULL, NULL);
+			g_return_val_if_fail (finish_strv == NULL, NULL);
+			g_return_val_if_fail (finish_uint == NULL, NULL);
+		}
 
-	if (finish_strv) {
-		g_return_val_if_fail (finish_void == NULL, NULL);
-		g_return_val_if_fail (finish_boolean == NULL, NULL);
-		g_return_val_if_fail (finish_string == NULL, NULL);
-		g_return_val_if_fail (finish_uint == NULL, NULL);
-	}
+		if (finish_boolean) {
+			g_return_val_if_fail (finish_void == NULL, NULL);
+			g_return_val_if_fail (finish_string == NULL, NULL);
+			g_return_val_if_fail (finish_strv == NULL, NULL);
+			g_return_val_if_fail (finish_uint == NULL, NULL);
+		}
 
-	if (finish_uint) {
-		g_return_val_if_fail (finish_void == NULL, NULL);
-		g_return_val_if_fail (finish_boolean == NULL, NULL);
-		g_return_val_if_fail (finish_string == NULL, NULL);
-		g_return_val_if_fail (finish_strv == NULL, NULL);
-	}
+		if (finish_string) {
+			g_return_val_if_fail (finish_void == NULL, NULL);
+			g_return_val_if_fail (finish_boolean == NULL, NULL);
+			g_return_val_if_fail (finish_strv == NULL, NULL);
+			g_return_val_if_fail (finish_uint == NULL, NULL);
+		}
 
-	*proxy = e_client_get_dbus_proxy (client);
-	if (!*proxy)
-		return NULL;
+		if (finish_strv) {
+			g_return_val_if_fail (finish_void == NULL, NULL);
+			g_return_val_if_fail (finish_boolean == NULL, NULL);
+			g_return_val_if_fail (finish_string == NULL, NULL);
+			g_return_val_if_fail (finish_uint == NULL, NULL);
+		}
+
+		if (finish_uint) {
+			g_return_val_if_fail (finish_void == NULL, NULL);
+			g_return_val_if_fail (finish_boolean == NULL, NULL);
+			g_return_val_if_fail (finish_string == NULL, NULL);
+			g_return_val_if_fail (finish_strv == NULL, NULL);
+		}
+
+		*proxy = e_client_get_dbus_proxy (client);
+		if (!*proxy)
+			return NULL;
+	}
 
 	use_cancellable = cancellable;
 	if (!use_cancellable)
 		use_cancellable = g_cancellable_new ();
 
-	*opid = e_client_register_op (client, use_cancellable);
+	opid = e_client_register_op (client, use_cancellable);
 	async_data = g_new0 (EClientAsyncOpData, 1);
 	async_data->client = g_object_ref (client);
-	async_data->opid = *opid;
+	async_data->opid = opid;
 	async_data->source_tag = source_tag;
 	async_data->callback = callback;
 	async_data->user_data = user_data;
@@ -1605,116 +1602,118 @@ prepare_async_data (EClient *client, GCancellable *cancellable, GAsyncReadyCallb
 	if (use_cancellable != cancellable)
 		g_object_unref (use_cancellable);
 
-	*out_cancellable = use_cancellable;
+	if (out_cancellable)
+		*out_cancellable = use_cancellable;
 
 	return async_data;
 }
 
-guint32
+void
+e_client_proxy_return_async_error (EClient *client, const GError *error, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag)
+{
+	EClientAsyncOpData *async_data;
+
+	g_return_if_fail (client != NULL);
+	g_return_if_fail (E_IS_CLIENT (client));
+	g_return_if_fail (error != NULL);
+	g_return_if_fail (callback != NULL);
+
+	async_data = prepare_async_data (client, NULL, callback, user_data, source_tag, TRUE, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
+	g_return_if_fail (async_data != NULL);
+
+	finish_async_op (async_data, error, TRUE);
+}
+
+void
 e_client_proxy_call_void (EClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag, void (*func) (GDBusProxy *proxy, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data), EClientProxyFinishVoidFunc finish_void, EClientProxyFinishBooleanFunc finish_boolean, EClientProxyFinishStringFunc finish_string, EClientProxyFinishStrvFunc finish_strv, EClientProxyFinishUintFunc finish_uint)
 {
 	EClientAsyncOpData *async_data;
-	guint32 opid = 0;
 	GDBusProxy *proxy = NULL;
 
-	g_return_val_if_fail (client != NULL, 0);
-	g_return_val_if_fail (E_IS_CLIENT (client), 0);
-	g_return_val_if_fail (callback != NULL, 0);
-	g_return_val_if_fail (source_tag != NULL, 0);
-	g_return_val_if_fail (func != NULL, 0);
+	g_return_if_fail (client != NULL);
+	g_return_if_fail (E_IS_CLIENT (client));
+	g_return_if_fail (callback != NULL);
+	g_return_if_fail (source_tag != NULL);
+	e_client_return_async_if_fail (func != NULL, client, callback, user_data, source_tag);
 
-	async_data = prepare_async_data (client, cancellable, callback, user_data, source_tag, finish_void, finish_boolean, finish_string, finish_strv, finish_uint, &proxy, &opid, &cancellable);
-	g_return_val_if_fail (async_data != NULL, 0);
+	async_data = prepare_async_data (client, cancellable, callback, user_data, source_tag, FALSE, finish_void, finish_boolean, finish_string, finish_strv, finish_uint, &proxy, &cancellable);
+	e_client_return_async_if_fail (async_data != NULL, client, callback, user_data, source_tag);
 
 	func (proxy, cancellable, async_result_ready_cb, async_data);
-
-	return opid;
 }
 
-guint32
+void
 e_client_proxy_call_boolean (EClient *client, gboolean in_boolean, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag, void (*func) (GDBusProxy *proxy, gboolean in_boolean, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data), EClientProxyFinishVoidFunc finish_void, EClientProxyFinishBooleanFunc finish_boolean, EClientProxyFinishStringFunc finish_string, EClientProxyFinishStrvFunc finish_strv, EClientProxyFinishUintFunc finish_uint)
 {
 	EClientAsyncOpData *async_data;
-	guint32 opid = 0;
 	GDBusProxy *proxy = NULL;
 
-	g_return_val_if_fail (client != NULL, 0);
-	g_return_val_if_fail (E_IS_CLIENT (client), 0);
-	g_return_val_if_fail (callback != NULL, 0);
-	g_return_val_if_fail (source_tag != NULL, 0);
-	g_return_val_if_fail (func != NULL, 0);
+	g_return_if_fail (client != NULL);
+	g_return_if_fail (E_IS_CLIENT (client));
+	g_return_if_fail (callback != NULL);
+	g_return_if_fail (source_tag != NULL);
+	e_client_return_async_if_fail (func != NULL, client, callback, user_data, source_tag);
 
-	async_data = prepare_async_data (client, cancellable, callback, user_data, source_tag, finish_void, finish_boolean, finish_string, finish_strv, finish_uint, &proxy, &opid, &cancellable);
-	g_return_val_if_fail (async_data != NULL, 0);
+	async_data = prepare_async_data (client, cancellable, callback, user_data, source_tag, FALSE, finish_void, finish_boolean, finish_string, finish_strv, finish_uint, &proxy, &cancellable);
+	e_client_return_async_if_fail (async_data != NULL, client, callback, user_data, source_tag);
 
 	func (proxy, in_boolean, cancellable, async_result_ready_cb, async_data);
-
-	return opid;
 }
 
-guint32
+void
 e_client_proxy_call_string (EClient *client, const gchar *in_string, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag, void (*func) (GDBusProxy *proxy, const gchar * in_string, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data), EClientProxyFinishVoidFunc finish_void, EClientProxyFinishBooleanFunc finish_boolean, EClientProxyFinishStringFunc finish_string, EClientProxyFinishStrvFunc finish_strv, EClientProxyFinishUintFunc finish_uint)
 {
 	EClientAsyncOpData *async_data;
-	guint32 opid = 0;
 	GDBusProxy *proxy = NULL;
 
-	g_return_val_if_fail (client != NULL, 0);
-	g_return_val_if_fail (E_IS_CLIENT (client), 0);
-	g_return_val_if_fail (callback != NULL, 0);
-	g_return_val_if_fail (source_tag != NULL, 0);
-	g_return_val_if_fail (func != NULL, 0);
-	g_return_val_if_fail (in_string != NULL, 0);
+	g_return_if_fail (client != NULL);
+	g_return_if_fail (E_IS_CLIENT (client));
+	g_return_if_fail (callback != NULL);
+	g_return_if_fail (source_tag != NULL);
+	e_client_return_async_if_fail (func != NULL, client, callback, user_data, source_tag);
+	e_client_return_async_if_fail (in_string != NULL, client, callback, user_data, source_tag);
 
-	async_data = prepare_async_data (client, cancellable, callback, user_data, source_tag, finish_void, finish_boolean, finish_string, finish_strv, finish_uint, &proxy, &opid, &cancellable);
-	g_return_val_if_fail (async_data != NULL, 0);
+	async_data = prepare_async_data (client, cancellable, callback, user_data, source_tag, FALSE, finish_void, finish_boolean, finish_string, finish_strv, finish_uint, &proxy, &cancellable);
+	e_client_return_async_if_fail (async_data != NULL, client, callback, user_data, source_tag);
 
 	func (proxy, in_string, cancellable, async_result_ready_cb, async_data);
-
-	return opid;
 }
 
-guint32
+void
 e_client_proxy_call_strv (EClient *client, const gchar * const *in_strv, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag, void (*func) (GDBusProxy *proxy, const gchar * const * in_strv, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data), EClientProxyFinishVoidFunc finish_void, EClientProxyFinishBooleanFunc finish_boolean, EClientProxyFinishStringFunc finish_string, EClientProxyFinishStrvFunc finish_strv, EClientProxyFinishUintFunc finish_uint)
 {
 	EClientAsyncOpData *async_data;
-	guint32 opid = 0;
 	GDBusProxy *proxy = NULL;
 
-	g_return_val_if_fail (client != NULL, 0);
-	g_return_val_if_fail (E_IS_CLIENT (client), 0);
-	g_return_val_if_fail (callback != NULL, 0);
-	g_return_val_if_fail (source_tag != NULL, 0);
-	g_return_val_if_fail (func != NULL, 0);
-	g_return_val_if_fail (in_strv != NULL, 0);
+	g_return_if_fail (client != NULL);
+	g_return_if_fail (E_IS_CLIENT (client));
+	g_return_if_fail (callback != NULL);
+	g_return_if_fail (source_tag != NULL);
+	e_client_return_async_if_fail (func != NULL, client, callback, user_data, source_tag);
+	e_client_return_async_if_fail (in_strv != NULL, client, callback, user_data, source_tag);
 
-	async_data = prepare_async_data (client, cancellable, callback, user_data, source_tag, finish_void, finish_boolean, finish_string, finish_strv, finish_uint, &proxy, &opid, &cancellable);
-	g_return_val_if_fail (async_data != NULL, 0);
+	async_data = prepare_async_data (client, cancellable, callback, user_data, source_tag, FALSE, finish_void, finish_boolean, finish_string, finish_strv, finish_uint, &proxy, &cancellable);
+	e_client_return_async_if_fail (async_data != NULL, client, callback, user_data, source_tag);
 
 	func (proxy, in_strv, cancellable, async_result_ready_cb, async_data);
-
-	return opid;
 }
 
-guint32
+void
 e_client_proxy_call_uint (EClient *client, guint in_uint, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag, void (*func) (GDBusProxy *proxy, guint in_uint, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data), EClientProxyFinishVoidFunc finish_void, EClientProxyFinishBooleanFunc finish_boolean, EClientProxyFinishStringFunc finish_string, EClientProxyFinishStrvFunc finish_strv, EClientProxyFinishUintFunc finish_uint)
 {
 	EClientAsyncOpData *async_data;
-	guint32 opid = 0;
 	GDBusProxy *proxy = NULL;
 
-	g_return_val_if_fail (client != NULL, 0);
-	g_return_val_if_fail (E_IS_CLIENT (client), 0);
-	g_return_val_if_fail (callback != NULL, 0);
-	g_return_val_if_fail (source_tag != NULL, 0);
-	g_return_val_if_fail (func != NULL, 0);
+	g_return_if_fail (client != NULL);
+	g_return_if_fail (E_IS_CLIENT (client));
+	g_return_if_fail (callback != NULL);
+	g_return_if_fail (source_tag != NULL);
+	e_client_return_async_if_fail (func != NULL, client, callback, user_data, source_tag);
 
-	async_data = prepare_async_data (client, cancellable, callback, user_data, source_tag, finish_void, finish_boolean, finish_string, finish_strv, finish_uint, &proxy, &opid, &cancellable);
-	g_return_val_if_fail (async_data != NULL, 0);
+	async_data = prepare_async_data (client, cancellable, callback, user_data, source_tag, FALSE, finish_void, finish_boolean, finish_string, finish_strv, finish_uint, &proxy, &cancellable);
+	e_client_return_async_if_fail (async_data != NULL, client, callback, user_data, source_tag);
 
 	func (proxy, in_uint, cancellable, async_result_ready_cb, async_data);
-
-	return opid;
 }
 
 gboolean
diff --git a/libedataserver/e-client.h b/libedataserver/e-client.h
index f341d66..26a6de1 100644
--- a/libedataserver/e-client.h
+++ b/libedataserver/e-client.h
@@ -76,11 +76,11 @@ struct _EClientClass {
 	GDBusProxy *	(* get_dbus_proxy) (EClient *client);
 	void		(* unwrap_dbus_error) (EClient *client, GError *dbus_error, GError **out_error);
 
-	guint32		(* open) (EClient *client, gboolean only_if_exists, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+	void		(* open) (EClient *client, gboolean only_if_exists, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 	gboolean	(* open_finish) (EClient *client, GAsyncResult *result, GError **error);
 	gboolean	(* open_sync) (EClient *client, gboolean only_if_exists, GCancellable *cancellable, GError **error);
 
-	guint32		(* remove) (EClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+	void		(* remove) (EClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 	gboolean	(* remove_finish) (EClient *client, GAsyncResult *result, GError **error);
 	gboolean	(* remove_sync) (EClient *client, GCancellable *cancellable, GError **error);
 
@@ -103,14 +103,13 @@ gboolean	e_client_is_readonly		(EClient *client);
 gboolean	e_client_is_online		(EClient *client);
 gboolean	e_client_is_opened		(EClient *client);
 
-void		e_client_cancel_op		(EClient *client, guint32 opid);
 void		e_client_cancel_all		(EClient *client);
 
-guint32		e_client_open			(EClient *client, gboolean only_if_exists, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_client_open			(EClient *client, gboolean only_if_exists, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_client_open_finish		(EClient *client, GAsyncResult *result, GError **error);
 gboolean	e_client_open_sync		(EClient *client, gboolean only_if_exists, GCancellable *cancellable, GError **error);
 
-guint32		e_client_remove			(EClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
+void		e_client_remove			(EClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data);
 gboolean	e_client_remove_finish		(EClient *client, GAsyncResult *result, GError **error);
 gboolean	e_client_remove_sync		(EClient *client, GCancellable *cancellable, GError **error);
 
@@ -143,17 +142,38 @@ ESource *	e_client_util_get_source_for_uri(ESourceList *source_list, const gchar
 GDBusProxy *	e_client_get_dbus_proxy		(EClient *client);
 void		e_client_unwrap_dbus_error	(EClient *client, GError *dbus_error, GError **out_error);
 
+void		e_client_proxy_return_async_error	(EClient *client, const GError *error, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag);
+
+#define e_client_return_async_if_fail(_expr, _client, _callback, _user_data, _source_tag)	\
+	G_STMT_START {										\
+		if (!G_LIKELY (_expr)) {							\
+			GError *error;								\
+												\
+			error = g_error_new (							\
+				E_CLIENT_ERROR, E_CLIENT_ERROR_INVALID_ARG,			\
+				"file %s:%d: %s: assertion `%s' failed",			\
+				__FILE__, __LINE__, G_STRFUNC, # _expr);			\
+												\
+			g_log (G_LOG_DOMAIN, G_LOG_LEVEL_CRITICAL, "%s", error->message);	\
+												\
+			e_client_proxy_return_async_error (					\
+				_client, error, _callback, _user_data, _source_tag);		\
+												\
+			g_error_free (error);							\
+		}										\
+	} G_STMT_END
+
 typedef gboolean (* EClientProxyFinishVoidFunc)		(GDBusProxy *proxy, GAsyncResult *result, GError **error);
 typedef gboolean (* EClientProxyFinishBooleanFunc)	(GDBusProxy *proxy, GAsyncResult *result, gboolean *out_boolean, GError **error);
 typedef gboolean (* EClientProxyFinishStringFunc)	(GDBusProxy *proxy, GAsyncResult *result, gchar **out_string, GError **error);
 typedef gboolean (* EClientProxyFinishStrvFunc)		(GDBusProxy *proxy, GAsyncResult *result, gchar ***out_strv, GError **error);
 typedef gboolean (* EClientProxyFinishUintFunc)		(GDBusProxy *proxy, GAsyncResult *result, guint *out_uint, GError **error);
 
-guint32		e_client_proxy_call_void	(EClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag, void (*func) (GDBusProxy *proxy, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data), EClientProxyFinishVoidFunc finish_void, EClientProxyFinishBooleanFunc finish_boolean, EClientProxyFinishStringFunc finish_string, EClientProxyFinishStrvFunc finish_strv, EClientProxyFinishUintFunc finish_uint);
-guint32		e_client_proxy_call_boolean	(EClient *client, gboolean in_boolean, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag, void (*func) (GDBusProxy *proxy, gboolean in_boolean, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data), EClientProxyFinishVoidFunc finish_void, EClientProxyFinishBooleanFunc finish_boolean, EClientProxyFinishStringFunc finish_string, EClientProxyFinishStrvFunc finish_strv, EClientProxyFinishUintFunc finish_uint);
-guint32		e_client_proxy_call_string	(EClient *client, const gchar *in_string, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag, void (*func) (GDBusProxy *proxy, const gchar * in_string, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data), EClientProxyFinishVoidFunc finish_void, EClientProxyFinishBooleanFunc finish_boolean, EClientProxyFinishStringFunc finish_string, EClientProxyFinishStrvFunc finish_strv, EClientProxyFinishUintFunc finish_uint);
-guint32		e_client_proxy_call_strv	(EClient *client, const gchar * const *in_strv, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag, void (*func) (GDBusProxy *proxy, const gchar * const * in_strv, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data), EClientProxyFinishVoidFunc finish_void, EClientProxyFinishBooleanFunc finish_boolean, EClientProxyFinishStringFunc finish_string, EClientProxyFinishStrvFunc finish_strv, EClientProxyFinishUintFunc finish_uint);
-guint32		e_client_proxy_call_uint	(EClient *client, guint in_uint, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag, void (*func) (GDBusProxy *proxy, guint in_uint, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data), EClientProxyFinishVoidFunc finish_void, EClientProxyFinishBooleanFunc finish_boolean, EClientProxyFinishStringFunc finish_string, EClientProxyFinishStrvFunc finish_strv, EClientProxyFinishUintFunc finish_uint);
+void		e_client_proxy_call_void	(EClient *client, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag, void (*func) (GDBusProxy *proxy, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data), EClientProxyFinishVoidFunc finish_void, EClientProxyFinishBooleanFunc finish_boolean, EClientProxyFinishStringFunc finish_string, EClientProxyFinishStrvFunc finish_strv, EClientProxyFinishUintFunc finish_uint);
+void		e_client_proxy_call_boolean	(EClient *client, gboolean in_boolean, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag, void (*func) (GDBusProxy *proxy, gboolean in_boolean, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data), EClientProxyFinishVoidFunc finish_void, EClientProxyFinishBooleanFunc finish_boolean, EClientProxyFinishStringFunc finish_string, EClientProxyFinishStrvFunc finish_strv, EClientProxyFinishUintFunc finish_uint);
+void		e_client_proxy_call_string	(EClient *client, const gchar *in_string, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag, void (*func) (GDBusProxy *proxy, const gchar * in_string, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data), EClientProxyFinishVoidFunc finish_void, EClientProxyFinishBooleanFunc finish_boolean, EClientProxyFinishStringFunc finish_string, EClientProxyFinishStrvFunc finish_strv, EClientProxyFinishUintFunc finish_uint);
+void		e_client_proxy_call_strv	(EClient *client, const gchar * const *in_strv, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag, void (*func) (GDBusProxy *proxy, const gchar * const * in_strv, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data), EClientProxyFinishVoidFunc finish_void, EClientProxyFinishBooleanFunc finish_boolean, EClientProxyFinishStringFunc finish_string, EClientProxyFinishStrvFunc finish_strv, EClientProxyFinishUintFunc finish_uint);
+void		e_client_proxy_call_uint	(EClient *client, guint in_uint, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data, gpointer source_tag, void (*func) (GDBusProxy *proxy, guint in_uint, GCancellable *cancellable, GAsyncReadyCallback callback, gpointer user_data), EClientProxyFinishVoidFunc finish_void, EClientProxyFinishBooleanFunc finish_boolean, EClientProxyFinishStringFunc finish_string, EClientProxyFinishStrvFunc finish_strv, EClientProxyFinishUintFunc finish_uint);
 
 gboolean	e_client_proxy_call_finish_void		(EClient *client, GAsyncResult *result, GError **error, gpointer source_tag);
 gboolean	e_client_proxy_call_finish_boolean	(EClient *client, GAsyncResult *result, gboolean *out_boolean, GError **error, gpointer source_tag);
diff --git a/tests/libebook/client/test-client-add-contact.c b/tests/libebook/client/test-client-add-contact.c
index 6da34b7..24b3de1 100644
--- a/tests/libebook/client/test-client-add-contact.c
+++ b/tests/libebook/client/test-client-add-contact.c
@@ -78,13 +78,7 @@ main (gint argc, gchar **argv)
 	contact = e_contact_new_from_vcard (vcard);
 	g_free (vcard);
 
-	if (!e_book_client_add_contact (book_client, contact, NULL, add_contact_cb, NULL)) {
-		report_error ("add contact", NULL);
-		g_object_unref (contact);
-		g_object_unref (book_client);
-		return 1;
-	}
-
+	e_book_client_add_contact (book_client, contact, NULL, add_contact_cb, NULL);
 	g_object_unref (contact);
 
 	start_main_loop (NULL, NULL);
diff --git a/tests/libebook/client/test-client-async.c b/tests/libebook/client/test-client-async.c
index c459b62..6e0ef97 100644
--- a/tests/libebook/client/test-client-async.c
+++ b/tests/libebook/client/test-client-async.c
@@ -40,12 +40,7 @@ print_all_emails (EBookClient *book_client)
 
 	query = e_book_query_field_exists (E_CONTACT_FULL_NAME);
 
-	if (!e_book_client_get_contacts (book_client, query, NULL, print_all_emails_cb, NULL)) {
-		e_book_query_unref (query);
-		report_error ("get contacts", NULL);
-		stop_main_loop (1);
-		return;
-	}
+	e_book_client_get_contacts (book_client, query, NULL, print_all_emails_cb, NULL);
 
 	e_book_query_unref (query);
 }
@@ -74,11 +69,7 @@ print_email_cb (GObject *source_object, GAsyncResult *result, gpointer user_data
 static void
 print_one_email (EBookClient *book_client)
 {
-	if (!e_book_client_get_contact (book_client, "pas-id-0002023", NULL, print_email_cb, NULL)) {
-		report_error ("get contact", NULL);
-		stop_main_loop (1);
-		return;
-	}
+	e_book_client_get_contact (book_client, "pas-id-0002023", NULL, print_email_cb, NULL);
 }
 
 static void
@@ -116,11 +107,7 @@ main (gint argc, gchar **argv)
 
 	printf ("loading addressbook\n");
 
-	if (!e_client_open (E_CLIENT (book_client), FALSE, NULL, client_loaded_cb, NULL)) {
-		g_object_unref (book_client);
-		report_error ("open client", NULL);
-		return 1;
-	}
+	e_client_open (E_CLIENT (book_client), FALSE, NULL, client_loaded_cb, NULL);
 
 	start_main_loop (NULL, NULL);
 
diff --git a/tests/libebook/client/test-client-get-book-view.c b/tests/libebook/client/test-client-get-book-view.c
index 605edfb..3e2b47a 100644
--- a/tests/libebook/client/test-client-get-book-view.c
+++ b/tests/libebook/client/test-client-get-book-view.c
@@ -97,10 +97,7 @@ call_get_book_view (gpointer user_data)
 
 	query = e_book_query_any_field_contains ("");
 
-	if (!e_book_client_get_view (book_client, query, NULL, get_book_view_cb, NULL)) {
-		report_error ("get book view", NULL);
-		stop_main_loop (1);
-	}
+	e_book_client_get_view (book_client, query, NULL, get_book_view_cb, NULL);
 
 	e_book_query_unref (query);
 
diff --git a/tests/libebook/client/test-client-get-capabilities.c b/tests/libebook/client/test-client-get-capabilities.c
index 4465c4c..8063eef 100644
--- a/tests/libebook/client/test-client-get-capabilities.c
+++ b/tests/libebook/client/test-client-get-capabilities.c
@@ -78,12 +78,8 @@ continue_next_source (gpointer async_data)
 			continue;
 		}
 
-		if (!e_client_open (E_CLIENT (book_client), TRUE, NULL, client_opened_async, async_data)) {
-			report_error ("client open", NULL);
-			g_object_unref (book_client);
-		} else {
-			break;
-		}
+		e_client_open (E_CLIENT (book_client), TRUE, NULL, client_opened_async, async_data);
+		break;
 	}
 
 	if (!async_data)
@@ -129,11 +125,7 @@ client_opened_async (GObject *source_object, GAsyncResult *result, gpointer asyn
 		return;
 	}
 
-	if (!e_book_client_get_capabilities (E_BOOK_CLIENT (source_object), NULL, client_got_values_async, async_data)) {
-		report_error ("get capabilities", NULL);
-		g_object_unref (source_object);
-		continue_next_source (async_data);
-	}
+	e_book_client_get_capabilities (E_BOOK_CLIENT (source_object), NULL, client_got_values_async, async_data);
 }
 
 static void
@@ -193,33 +185,21 @@ in_main_thread_idle_cb (gpointer unused)
 
 	printf ("* run in main thread async\n");
 
-	while (TRUE) {
-		identify_source (source);
-
-		while (book_client = e_book_client_new (source, &error), !book_client) {
-			report_error ("book client new", &error);
+	identify_source (source);
 
-			if (!foreach_configured_source_async_next (&async_data, &source)) {
-				stop_main_loop (0);
-				return FALSE;
-			}
+	while (book_client = e_book_client_new (source, &error), !book_client) {
+		report_error ("book client new", &error);
 
-			identify_source (source);
+		if (!foreach_configured_source_async_next (&async_data, &source)) {
+			stop_main_loop (0);
+			return FALSE;
 		}
 
-		if (!e_client_open (E_CLIENT (book_client), TRUE, NULL, client_opened_async, async_data)) {
-			report_error ("client open", NULL);
-			g_object_unref (book_client);
-
-			if (!foreach_configured_source_async_next (&async_data, &source)) {
-				stop_main_loop (0);
-				return FALSE;
-			}
-		} else {
-			break;
-		}
+		identify_source (source);
 	}
 
+	e_client_open (E_CLIENT (book_client), TRUE, NULL, client_opened_async, async_data);
+
 	return FALSE;
 }
 
diff --git a/tests/libebook/client/test-client-get-contact.c b/tests/libebook/client/test-client-get-contact.c
index 0a480ca..7a8e0b7 100644
--- a/tests/libebook/client/test-client-get-contact.c
+++ b/tests/libebook/client/test-client-get-contact.c
@@ -52,12 +52,7 @@ main (gint argc, gchar **argv)
 	/*
 	 * Async version
 	 */
-	if (!e_book_client_get_contact (book_client, e_contact_get_const (contact_final, E_CONTACT_UID), NULL, contact_ready_cb, NULL)) {
-		report_error ("get contact", NULL);
-		g_object_unref (contact_final);
-		g_object_unref (book_client);
-		return 1;
-	}
+	e_book_client_get_contact (book_client, e_contact_get_const (contact_final, E_CONTACT_UID), NULL, contact_ready_cb, NULL);
 
 	g_object_unref (contact_final);
 
diff --git a/tests/libebook/client/test-client-get-required-fields.c b/tests/libebook/client/test-client-get-required-fields.c
index d4ee401..279d523 100644
--- a/tests/libebook/client/test-client-get-required-fields.c
+++ b/tests/libebook/client/test-client-get-required-fields.c
@@ -63,12 +63,8 @@ continue_next_source (gpointer async_data)
 			continue;
 		}
 
-		if (!e_client_open (E_CLIENT (book_client), TRUE, NULL, client_opened_async, async_data)) {
-			report_error ("client open", NULL);
-			g_object_unref (book_client);
-		} else {
-			break;
-		}
+		e_client_open (E_CLIENT (book_client), TRUE, NULL, client_opened_async, async_data);
+		break;
 	}
 
 	if (!async_data)
@@ -114,11 +110,7 @@ client_opened_async (GObject *source_object, GAsyncResult *result, gpointer asyn
 		return;
 	}
 
-	if (!e_book_client_get_required_fields (E_BOOK_CLIENT (source_object), NULL, client_got_values_async, async_data)) {
-		report_error ("get required fields", NULL);
-		g_object_unref (source_object);
-		continue_next_source (async_data);
-	}
+	e_book_client_get_required_fields (E_BOOK_CLIENT (source_object), NULL, client_got_values_async, async_data);
 }
 
 static void
@@ -178,33 +170,21 @@ in_main_thread_idle_cb (gpointer unused)
 
 	printf ("* run in main thread async\n");
 
-	while (TRUE) {
-		identify_source (source);
-
-		while (book_client = e_book_client_new (source, &error), !book_client) {
-			report_error ("book client new", &error);
+	identify_source (source);
 
-			if (!foreach_configured_source_async_next (&async_data, &source)) {
-				stop_main_loop (0);
-				return FALSE;
-			}
+	while (book_client = e_book_client_new (source, &error), !book_client) {
+		report_error ("book client new", &error);
 
-			identify_source (source);
+		if (!foreach_configured_source_async_next (&async_data, &source)) {
+			stop_main_loop (0);
+			return FALSE;
 		}
 
-		if (!e_client_open (E_CLIENT (book_client), TRUE, NULL, client_opened_async, async_data)) {
-			report_error ("client open", NULL);
-			g_object_unref (book_client);
-
-			if (!foreach_configured_source_async_next (&async_data, &source)) {
-				stop_main_loop (0);
-				return FALSE;
-			}
-		} else {
-			break;
-		}
+		identify_source (source);
 	}
 
+	e_client_open (E_CLIENT (book_client), TRUE, NULL, client_opened_async, async_data);
+
 	return FALSE;
 }
 
diff --git a/tests/libebook/client/test-client-get-supported-auth-methods.c b/tests/libebook/client/test-client-get-supported-auth-methods.c
index 2fbb2f7..768a3bf 100644
--- a/tests/libebook/client/test-client-get-supported-auth-methods.c
+++ b/tests/libebook/client/test-client-get-supported-auth-methods.c
@@ -63,12 +63,8 @@ continue_next_source (gpointer async_data)
 			continue;
 		}
 
-		if (!e_client_open (E_CLIENT (book_client), TRUE, NULL, client_opened_async, async_data)) {
-			report_error ("client open", NULL);
-			g_object_unref (book_client);
-		} else {
-			break;
-		}
+		e_client_open (E_CLIENT (book_client), TRUE, NULL, client_opened_async, async_data);
+		break;
 	}
 
 	if (!async_data)
@@ -114,11 +110,7 @@ client_opened_async (GObject *source_object, GAsyncResult *result, gpointer asyn
 		return;
 	}
 
-	if (!e_book_client_get_supported_auth_methods (E_BOOK_CLIENT (source_object), NULL, client_got_values_async, async_data)) {
-		report_error ("get supported auth methods", NULL);
-		g_object_unref (source_object);
-		continue_next_source (async_data);
-	}
+	e_book_client_get_supported_auth_methods (E_BOOK_CLIENT (source_object), NULL, client_got_values_async, async_data);
 }
 
 static void
@@ -178,33 +170,21 @@ in_main_thread_idle_cb (gpointer unused)
 
 	printf ("* run in main thread async\n");
 
-	while (TRUE) {
-		identify_source (source);
-
-		while (book_client = e_book_client_new (source, &error), !book_client) {
-			report_error ("book client new", &error);
+	identify_source (source);
 
-			if (!foreach_configured_source_async_next (&async_data, &source)) {
-				stop_main_loop (0);
-				return FALSE;
-			}
+	while (book_client = e_book_client_new (source, &error), !book_client) {
+		report_error ("book client new", &error);
 
-			identify_source (source);
+		if (!foreach_configured_source_async_next (&async_data, &source)) {
+			stop_main_loop (0);
+			return FALSE;
 		}
 
-		if (!e_client_open (E_CLIENT (book_client), TRUE, NULL, client_opened_async, async_data)) {
-			report_error ("client open", NULL);
-			g_object_unref (book_client);
-
-			if (!foreach_configured_source_async_next (&async_data, &source)) {
-				stop_main_loop (0);
-				return FALSE;
-			}
-		} else {
-			break;
-		}
+		identify_source (source);
 	}
 
+	e_client_open (E_CLIENT (book_client), TRUE, NULL, client_opened_async, async_data);
+
 	return FALSE;
 }
 
diff --git a/tests/libebook/client/test-client-get-supported-fields.c b/tests/libebook/client/test-client-get-supported-fields.c
index 3b29aec..17a334e 100644
--- a/tests/libebook/client/test-client-get-supported-fields.c
+++ b/tests/libebook/client/test-client-get-supported-fields.c
@@ -63,12 +63,8 @@ continue_next_source (gpointer async_data)
 			continue;
 		}
 
-		if (!e_client_open (E_CLIENT (book_client), TRUE, NULL, client_opened_async, async_data)) {
-			report_error ("client open", NULL);
-			g_object_unref (book_client);
-		} else {
-			break;
-		}
+		e_client_open (E_CLIENT (book_client), TRUE, NULL, client_opened_async, async_data);
+		break;
 	}
 
 	if (!async_data)
@@ -114,11 +110,7 @@ client_opened_async (GObject *source_object, GAsyncResult *result, gpointer asyn
 		return;
 	}
 
-	if (!e_book_client_get_supported_fields (E_BOOK_CLIENT (source_object), NULL, client_got_values_async, async_data)) {
-		report_error ("get supported fields", NULL);
-		g_object_unref (source_object);
-		continue_next_source (async_data);
-	}
+	e_book_client_get_supported_fields (E_BOOK_CLIENT (source_object), NULL, client_got_values_async, async_data);
 }
 
 static void
@@ -178,33 +170,21 @@ in_main_thread_idle_cb (gpointer unused)
 
 	printf ("* run in main thread async\n");
 
-	while (TRUE) {
-		identify_source (source);
-
-		while (book_client = e_book_client_new (source, &error), !book_client) {
-			report_error ("book client new", &error);
+	identify_source (source);
 
-			if (!foreach_configured_source_async_next (&async_data, &source)) {
-				stop_main_loop (0);
-				return FALSE;
-			}
+	while (book_client = e_book_client_new (source, &error), !book_client) {
+		report_error ("book client new", &error);
 
-			identify_source (source);
+		if (!foreach_configured_source_async_next (&async_data, &source)) {
+			stop_main_loop (0);
+			return FALSE;
 		}
 
-		if (!e_client_open (E_CLIENT (book_client), TRUE, NULL, client_opened_async, async_data)) {
-			report_error ("client open", NULL);
-			g_object_unref (book_client);
-
-			if (!foreach_configured_source_async_next (&async_data, &source)) {
-				stop_main_loop (0);
-				return FALSE;
-			}
-		} else {
-			break;
-		}
+		identify_source (source);
 	}
 
+	e_client_open (E_CLIENT (book_client), TRUE, NULL, client_opened_async, async_data);
+
 	return FALSE;
 }
 
diff --git a/tests/libebook/client/test-client-modify-contact.c b/tests/libebook/client/test-client-modify-contact.c
index 19126af..309e370 100644
--- a/tests/libebook/client/test-client-modify-contact.c
+++ b/tests/libebook/client/test-client-modify-contact.c
@@ -62,11 +62,7 @@ contact_modified_cb (GObject *source_object, GAsyncResult *result, gpointer user
 		return;
 	}
 
-	if (!e_book_client_get_contact (E_BOOK_CLIENT (source_object), e_contact_get_const (contact, E_CONTACT_UID), NULL, contact_ready_cb, NULL)) {
-		report_error ("get contact", NULL);
-		stop_main_loop (1);
-		return;
-	}
+	e_book_client_get_contact (E_BOOK_CLIENT (source_object), e_contact_get_const (contact, E_CONTACT_UID), NULL, contact_ready_cb, NULL);
 }
 
 gint
@@ -145,12 +141,7 @@ main (gint argc, gchar **argv)
 
 	verify_premodify_and_prepare_contact (contact);
 
-	if (!e_book_client_modify_contact (book_client, contact, NULL, contact_modified_cb, contact)) {
-		report_error ("modify contact", NULL);
-		g_object_unref (book_client);
-		g_object_unref (contact);
-		return 1;
-	}
+	e_book_client_modify_contact (book_client, contact, NULL, contact_modified_cb, contact);
 
 	start_main_loop (NULL, NULL);
 
diff --git a/tests/libebook/client/test-client-remove-contact-by-uid.c b/tests/libebook/client/test-client-remove-contact-by-uid.c
index fd571c1..b55615a 100644
--- a/tests/libebook/client/test-client-remove-contact-by-uid.c
+++ b/tests/libebook/client/test-client-remove-contact-by-uid.c
@@ -109,12 +109,7 @@ main (gint argc, gchar **argv)
 
 	uid = e_contact_get (contact, E_CONTACT_UID);
 	g_object_unref (contact);
-	if (!e_book_client_remove_contact_by_uid (book_client, uid, NULL, remove_contact_by_uid_cb, uid)) {
-		report_error ("remove contact", NULL);
-		g_free (uid);
-		g_object_unref (book_client);
-		return 1;
-	}
+	e_book_client_remove_contact_by_uid (book_client, uid, NULL, remove_contact_by_uid_cb, uid);
 
 	start_main_loop (NULL, NULL);
 
diff --git a/tests/libebook/client/test-client-remove-contact.c b/tests/libebook/client/test-client-remove-contact.c
index b948b9f..f944684 100644
--- a/tests/libebook/client/test-client-remove-contact.c
+++ b/tests/libebook/client/test-client-remove-contact.c
@@ -110,13 +110,7 @@ main (gint argc, gchar **argv)
 	}
 
 	uid = e_contact_get (contact, E_CONTACT_UID);
-	if (!e_book_client_remove_contact (book_client, contact, NULL, remove_contact_cb, uid)) {
-		report_error ("remove contact", NULL);
-		g_free (uid);
-		g_object_unref (contact);
-		g_object_unref (book_client);
-		return 1;
-	}
+	e_book_client_remove_contact (book_client, contact, NULL, remove_contact_cb, uid);
 
 	g_object_unref (contact);
 
diff --git a/tests/libebook/client/test-client-remove-contacts.c b/tests/libebook/client/test-client-remove-contacts.c
index 30fd641..49c4dd1 100644
--- a/tests/libebook/client/test-client-remove-contacts.c
+++ b/tests/libebook/client/test-client-remove-contacts.c
@@ -141,13 +141,7 @@ main (gint argc, gchar **argv)
 		return 1;
 	}
 
-	if (!e_book_client_remove_contacts (book_client, uids, NULL, remove_contacts_cb, uids)) {
-		report_error ("remove contact", NULL);
-		g_slist_foreach (uids, (GFunc) g_free, NULL);
-		g_slist_free (uids);
-		g_object_unref (book_client);
-		return 1;
-	}
+	e_book_client_remove_contacts (book_client, uids, NULL, remove_contacts_cb, uids);
 
 	start_main_loop (NULL, NULL);
 
diff --git a/tests/libebook/client/test-client-remove.c b/tests/libebook/client/test-client-remove.c
index 7371377..a463f4b 100644
--- a/tests/libebook/client/test-client-remove.c
+++ b/tests/libebook/client/test-client-remove.c
@@ -59,11 +59,7 @@ main (gint argc, gchar **argv)
 		return 1;
 	}
 
-	if (!e_client_remove (E_CLIENT (book_client), NULL, client_removed_cb, NULL)) {
-		report_error ("client remove", NULL);
-		g_object_unref (book_client);
-		return 1;
-	}
+	e_client_remove (E_CLIENT (book_client), NULL, client_removed_cb, NULL);
 
 	start_main_loop (NULL, NULL);
 
diff --git a/tests/libecal/client/test-client-add-timezone.c b/tests/libecal/client/test-client-add-timezone.c
index caae6ed..b003801 100644
--- a/tests/libecal/client/test-client-add-timezone.c
+++ b/tests/libecal/client/test-client-add-timezone.c
@@ -123,11 +123,7 @@ async_write_result_ready (GObject *source_object, GAsyncResult *result, gpointer
 		return;
 	}
 
-	if (!e_cal_client_get_timezone (cal_client, TZID_NEW, NULL, async_read_result_ready, user_data)) {
-		report_error ("get timezone", NULL);
-		g_object_unref (cal_client);
-		stop_main_loop (1);
-	}
+	e_cal_client_get_timezone (cal_client, TZID_NEW, NULL, async_read_result_ready, user_data);
 }
 
 /* synchronously in idle with main-loop running */
@@ -155,12 +151,7 @@ test_sync_in_idle (gpointer user_data)
 		return FALSE;
 	}
 
-	if (!e_cal_client_add_timezone (cal_client, zone, NULL, async_write_result_ready, zone)) {
-		report_error ("add timezone", NULL);
-		g_object_unref (cal_client);
-		stop_main_loop (1);
-		return FALSE;
-	}
+	e_cal_client_add_timezone (cal_client, zone, NULL, async_write_result_ready, zone);
 
 	return FALSE;
 }
diff --git a/tests/libecal/client/test-client-create-object.c b/tests/libecal/client/test-client-create-object.c
index 8eedba2..dc95a24 100644
--- a/tests/libecal/client/test-client-create-object.c
+++ b/tests/libecal/client/test-client-create-object.c
@@ -169,7 +169,6 @@ async_read_result_ready (GObject *source_object, GAsyncResult *result, gpointer
 	ECalClient *cal_client;
 	GError *error = NULL;
 	icalcomponent *icalcomp1 = user_data, *icalcomp2 = NULL;
-	gboolean res;
 
 	g_return_if_fail (icalcomp1 != NULL);
 
@@ -183,22 +182,11 @@ async_read_result_ready (GObject *source_object, GAsyncResult *result, gpointer
 		return;
 	}
 
-	res = test_icalcomps (icalcomp1, icalcomp2);
+	test_icalcomps (icalcomp1, icalcomp2);
 
 	icalcomponent_free (icalcomp2);
 
-	if (!e_cal_client_get_objects_for_uid (cal_client, icalcomponent_get_uid (icalcomp1), NULL, async_read2_result_ready, icalcomp1)) {
-		report_error ("get objects for uid", NULL);
-
-		if (!e_client_remove_sync (E_CLIENT (cal_client), NULL, &error)) {
-			report_error ("client remove sync", &error);
-		}
-
-		g_object_unref (cal_client);
-		icalcomponent_free (icalcomp1);
-
-		stop_main_loop (res ? 0 : 1);
-	}
+	e_cal_client_get_objects_for_uid (cal_client, icalcomponent_get_uid (icalcomp1), NULL, async_read2_result_ready, icalcomp1);
 }
 
 /* asynchronous write callback with a main-loop running */
@@ -224,12 +212,7 @@ async_write_result_ready (GObject *source_object, GAsyncResult *result, gpointer
 	clone = icalcomponent_new_clone (icalcomp);
 	icalcomponent_set_uid (clone, uid);
 
-	if (!e_cal_client_get_object (cal_client, uid, NULL, NULL, async_read_result_ready, clone)) {
-		report_error ("get object", NULL);
-		g_object_unref (cal_client);
-		icalcomponent_free (clone);
-		stop_main_loop (1);
-	}
+	e_cal_client_get_object (cal_client, uid, NULL, NULL, async_read_result_ready, clone);
 
 	g_free (uid);
 }
@@ -259,12 +242,7 @@ test_sync_in_idle (gpointer user_data)
 		return FALSE;
 	}
 
-	if (!e_cal_client_create_object (cal_client, icalcomp, NULL, async_write_result_ready, icalcomp)) {
-		report_error ("create object", NULL);
-		g_object_unref (cal_client);
-		stop_main_loop (1);
-		return FALSE;
-	}
+	e_cal_client_create_object (cal_client, icalcomp, NULL, async_write_result_ready, icalcomp);
 
 	return FALSE;
 }
diff --git a/tests/libecal/client/test-client-examine.c b/tests/libecal/client/test-client-examine.c
index cb31bde..f32e9a1 100644
--- a/tests/libecal/client/test-client-examine.c
+++ b/tests/libecal/client/test-client-examine.c
@@ -159,13 +159,8 @@ continue_next_source (gpointer async_data)
 			continue;
 		}
 
-		if (!e_client_open (E_CLIENT (cal_client), TRUE, NULL, client_opened_async, async_data)) {
-			identify_source (source, source_type);
-			report_error ("client open", NULL);
-			g_object_unref (cal_client);
-		} else {
-			break;
-		}
+		e_client_open (E_CLIENT (cal_client), TRUE, NULL, client_opened_async, async_data);
+		break;
 	}
 
 	if (!async_data) {
@@ -232,13 +227,7 @@ client_got_alarm_email_address_async (GObject *source_object, GAsyncResult *resu
 		return;
 	}
 
-	if (!e_cal_client_get_capabilities (cal_client, NULL, client_got_values_async, evals)) {
-		identify_cal_client (cal_client);
-		report_error ("get capabilities", NULL);
-		g_object_unref (source_object);
-		continue_next_source (evals->async_data);
-		extra_values_free (evals);
-	}
+	e_cal_client_get_capabilities (cal_client, NULL, client_got_values_async, evals);
 }
 
 static void
@@ -263,13 +252,7 @@ client_got_cal_address_async (GObject *source_object, GAsyncResult *result, gpoi
 		return;
 	}
 
-	if (!e_cal_client_get_alarm_email_address (cal_client, NULL, client_got_alarm_email_address_async, evals)) {
-		identify_cal_client (cal_client);
-		report_error ("get alarm email address", NULL);
-		g_object_unref (source_object);
-		continue_next_source (evals->async_data);
-		extra_values_free (evals);
-	}
+	e_cal_client_get_alarm_email_address (cal_client, NULL, client_got_alarm_email_address_async, evals);
 }
 
 static void
@@ -290,13 +273,7 @@ client_got_default_object_async (GObject *source_object, GAsyncResult *result, g
 		report_error ("get default object finish", &error);
 	}
 
-	if (!e_cal_client_get_cal_email_address (cal_client, NULL, client_got_cal_address_async, evals)) {
-		identify_cal_client (cal_client);
-		report_error ("get cal address", NULL);
-		g_object_unref (source_object);
-		continue_next_source (evals->async_data);
-		extra_values_free (evals);
-	}
+	e_cal_client_get_cal_email_address (cal_client, NULL, client_got_cal_address_async, evals);
 }
 
 static void
@@ -323,13 +300,7 @@ client_opened_async (GObject *source_object, GAsyncResult *result, gpointer asyn
 	evals = g_new0 (ExtraValues, 1);
 	evals->async_data = async_data;
 	
-	if (!e_cal_client_get_default_object (cal_client, NULL, client_got_default_object_async, evals)) {
-		identify_cal_client (cal_client);
-		report_error ("get default object", NULL);
-		g_object_unref (source_object);
-		continue_next_source (async_data);
-		extra_values_free (evals);
-	}
+	e_cal_client_get_default_object (cal_client, NULL, client_got_default_object_async, evals);
 }
 
 static void
@@ -401,37 +372,22 @@ foreach_async (ECalClientSourceType source_type)
 
 	running_async++;
 
-	while (TRUE) {
-		while (cal_client = e_cal_client_new (source, source_type, &error), !cal_client) {
-			identify_source (source, source_type);
-			report_error ("cal client new", &error);
-
-			if (!foreach_configured_source_async_next (&async_data, &source)) {
-				running_async--;
-				if (!running_async)
-					stop_main_loop (0);
-				return FALSE;
-			}
+	while (cal_client = e_cal_client_new (source, source_type, &error), !cal_client) {
+		identify_source (source, source_type);
+		report_error ("cal client new", &error);
 
-			identify_source (source, source_type);
+		if (!foreach_configured_source_async_next (&async_data, &source)) {
+			running_async--;
+			if (!running_async)
+				stop_main_loop (0);
+			return FALSE;
 		}
 
-		if (!e_client_open (E_CLIENT (cal_client), TRUE, NULL, client_opened_async, async_data)) {
-			identify_source (source, source_type);
-			report_error ("client open", NULL);
-			g_object_unref (cal_client);
-
-			if (!foreach_configured_source_async_next (&async_data, &source)) {
-				running_async--;
-				if (!running_async)
-					stop_main_loop (0);
-				return FALSE;
-			}
-		} else {
-			break;
-		}
+		identify_source (source, source_type);
 	}
 
+	e_client_open (E_CLIENT (cal_client), TRUE, NULL, client_opened_async, async_data);
+
 	return TRUE;
 }
 
diff --git a/tests/libecal/client/test-client-get-attachment-uris.c b/tests/libecal/client/test-client-get-attachment-uris.c
index 312d6de..f7d9ecc 100644
--- a/tests/libecal/client/test-client-get-attachment-uris.c
+++ b/tests/libecal/client/test-client-get-attachment-uris.c
@@ -77,7 +77,6 @@ static gboolean
 test_sync_in_idle (gpointer user_data)
 {
 	ECalClient *cal_client = user_data;
-	GError *error = NULL;
 	const gchar *uid;
 
 	g_return_val_if_fail (cal_client != NULL, FALSE);
@@ -90,11 +89,7 @@ test_sync_in_idle (gpointer user_data)
 
 	uid = g_object_get_data (G_OBJECT (cal_client), "use-uid");
 
-	if (!e_cal_client_get_attachment_uris (cal_client, uid, NULL, NULL, async_attachment_uris_result_ready, NULL)) {
-		report_error ("get attachment uris", &error);
-		stop_main_loop (1);
-		return FALSE;
-	}
+	e_cal_client_get_attachment_uris (cal_client, uid, NULL, NULL, async_attachment_uris_result_ready, NULL);
 
 	return FALSE;
 }
diff --git a/tests/libecal/client/test-client-get-free-busy.c b/tests/libecal/client/test-client-get-free-busy.c
index 3d5943c..90466c5 100644
--- a/tests/libecal/client/test-client-get-free-busy.c
+++ b/tests/libecal/client/test-client-get-free-busy.c
@@ -125,13 +125,7 @@ test_async_in_idle (gpointer user_data)
 	/* here is all Free/Busy information received */
 	g_signal_connect (cal_client, "free-busy-data", G_CALLBACK (free_busy_data_cb), (gpointer) G_STRFUNC);
 
-	if (!e_cal_client_get_free_busy (cal_client, start, end, users, NULL, async_get_free_busy_result_ready, NULL)) {
-		report_error ("get free busy", NULL);
-		g_object_unref (cal_client);
-		g_slist_free (users);
-		stop_main_loop (1);
-		return FALSE;
-	}
+	e_cal_client_get_free_busy (cal_client, start, end, users, NULL, async_get_free_busy_result_ready, NULL);
 
 	g_slist_free (users);
 
diff --git a/tests/libecal/client/test-client-get-object-list.c b/tests/libecal/client/test-client-get-object-list.c
index 001136e..15d9832 100644
--- a/tests/libecal/client/test-client-get-object-list.c
+++ b/tests/libecal/client/test-client-get-object-list.c
@@ -108,10 +108,7 @@ async_get_object_list_result_ready (GObject *source_object, GAsyncResult *result
 
 	e_cal_client_free_icalcomp_slist (icalcomps);
 
-	if (!e_cal_client_get_object_list_as_comps (cal_client, EVENT_QUERY, NULL, async_get_object_list_as_comps_result_ready, NULL)) {
-		report_error ("get object list as comps", NULL);
-		stop_main_loop (1);
-	}
+	e_cal_client_get_object_list_as_comps (cal_client, EVENT_QUERY, NULL, async_get_object_list_as_comps_result_ready, NULL);
 }
 
 /* synchronously in idle with main-loop running */
@@ -128,11 +125,7 @@ test_sync_in_idle (gpointer user_data)
 		return FALSE;
 	}
 
-	if (!e_cal_client_get_object_list (cal_client, EVENT_QUERY, NULL, async_get_object_list_result_ready, NULL)) {
-		report_error ("get object list", NULL);
-		stop_main_loop (1);
-		return FALSE;
-	}
+	e_cal_client_get_object_list (cal_client, EVENT_QUERY, NULL, async_get_object_list_result_ready, NULL);
 
 	return FALSE;
 }
diff --git a/tests/libecal/client/test-client-get-view.c b/tests/libecal/client/test-client-get-view.c
index 7c42a67..c0cb076 100644
--- a/tests/libecal/client/test-client-get-view.c
+++ b/tests/libecal/client/test-client-get-view.c
@@ -159,10 +159,7 @@ get_view_async (gpointer user_data)
 
 	g_return_val_if_fail (user_data != NULL, NULL);
 
-	if (!e_cal_client_get_view (cal_client, "(contains? \"any\" \"event\")", NULL, async_get_view_ready, NULL)) {
-		report_error ("get view", NULL);
-		stop_main_loop (1);
-	}
+	e_cal_client_get_view (cal_client, "(contains? \"any\" \"event\")", NULL, async_get_view_ready, NULL);
 
 	return NULL;
 }
diff --git a/tests/libecal/client/test-client-modify-object.c b/tests/libecal/client/test-client-modify-object.c
index 8ca9393..75e67e0 100644
--- a/tests/libecal/client/test-client-modify-object.c
+++ b/tests/libecal/client/test-client-modify-object.c
@@ -113,12 +113,7 @@ test_sync_in_idle (gpointer user_data)
 
 	icalcomponent_set_summary (icalcomp, EVENT_SUMMARY);
 
-	if (!e_cal_client_modify_object (cal_client, icalcomp, CALOBJ_MOD_ALL, NULL, async_modify_result_ready, NULL)) {
-		report_error ("modify object", &error);
-		icalcomponent_free (icalcomp);
-		stop_main_loop (1);
-		return FALSE;
-	}
+	e_cal_client_modify_object (cal_client, icalcomp, CALOBJ_MOD_ALL, NULL, async_modify_result_ready, NULL);
 
 	icalcomponent_free (icalcomp);
 
diff --git a/tests/libecal/client/test-client-open.c b/tests/libecal/client/test-client-open.c
index e1c6afb..6493ce2 100644
--- a/tests/libecal/client/test-client-open.c
+++ b/tests/libecal/client/test-client-open.c
@@ -69,12 +69,7 @@ async_open_ready (GObject *source_object, GAsyncResult *result, gpointer user_da
 		return;
 	}
 
-	if (!e_client_remove (E_CLIENT (cal_client), NULL, async_remove_ready, NULL)) {
-		report_error ("client remove", NULL);
-		g_object_unref (cal_client);
-		stop_main_loop (1);
-		return;
-	}
+	e_client_remove (E_CLIENT (cal_client), NULL, async_remove_ready, NULL);
 }
 
 /* synchronously in idle with main-loop running */
@@ -91,12 +86,7 @@ test_sync_in_idle (gpointer user_data)
 	cal_client = new_temp_client (E_CAL_CLIENT_SOURCE_TYPE_EVENT, NULL);
 	g_return_val_if_fail (cal_client != NULL, FALSE);
 
-	if (!e_client_open (E_CLIENT (cal_client), FALSE, NULL, async_open_ready, NULL)) {
-		report_error ("client open", NULL);
-		g_object_unref (cal_client);
-		stop_main_loop (1);
-		return FALSE;
-	}
+	e_client_open (E_CLIENT (cal_client), FALSE, NULL, async_open_ready, NULL);
 
 	return FALSE;
 }
diff --git a/tests/libecal/client/test-client-receive-objects.c b/tests/libecal/client/test-client-receive-objects.c
index 6f2f5f5..a78d490 100644
--- a/tests/libecal/client/test-client-receive-objects.c
+++ b/tests/libecal/client/test-client-receive-objects.c
@@ -65,7 +65,6 @@ static gboolean
 test_sync_in_idle (gpointer user_data)
 {
 	ECalClient *cal_client = user_data;
-	GError *error = NULL;
 	icalcomponent *icalcomp;
 
 	g_return_val_if_fail (cal_client != NULL, FALSE);
@@ -82,12 +81,7 @@ test_sync_in_idle (gpointer user_data)
 		return FALSE;
 	}
 
-	if (!e_cal_client_receive_objects (cal_client, icalcomp, NULL, async_receive_result_ready, NULL)) {
-		report_error ("receive objects", &error);
-		icalcomponent_free (icalcomp);
-		stop_main_loop (1);
-		return FALSE;
-	}
+	e_cal_client_receive_objects (cal_client, icalcomp, NULL, async_receive_result_ready, NULL);
 
 	icalcomponent_free (icalcomp);
 
diff --git a/tests/libecal/client/test-client-refresh.c b/tests/libecal/client/test-client-refresh.c
index 1f44474..f101411 100644
--- a/tests/libecal/client/test-client-refresh.c
+++ b/tests/libecal/client/test-client-refresh.c
@@ -43,7 +43,6 @@ static gboolean
 test_sync_in_idle (gpointer user_data)
 {
 	ECalClient *cal_client = user_data;
-	GError *error = NULL;
 
 	g_return_val_if_fail (cal_client != NULL, FALSE);
 	g_return_val_if_fail (E_IS_CAL_CLIENT (cal_client), FALSE);
@@ -53,11 +52,7 @@ test_sync_in_idle (gpointer user_data)
 		return FALSE;
 	}
 
-	if (!e_cal_client_refresh (cal_client, NULL, async_refresh_result_ready, NULL)) {
-		report_error ("refresh", &error);
-		stop_main_loop (1);
-		return FALSE;
-	}
+	e_cal_client_refresh (cal_client, NULL, async_refresh_result_ready, NULL);
 
 	return FALSE;
 }
diff --git a/tests/libecal/client/test-client-remove-object.c b/tests/libecal/client/test-client-remove-object.c
index e83f474..6be0beb 100644
--- a/tests/libecal/client/test-client-remove-object.c
+++ b/tests/libecal/client/test-client-remove-object.c
@@ -79,7 +79,6 @@ static gboolean
 test_sync_in_idle (gpointer user_data)
 {
 	ECalClient *cal_client = user_data;
-	GError *error = NULL;
 	gchar *uid;
 
 	g_return_val_if_fail (cal_client != NULL, FALSE);
@@ -96,12 +95,7 @@ test_sync_in_idle (gpointer user_data)
 		return FALSE;
 	}
 
-	if (!e_cal_client_remove_object (cal_client, uid, NULL, CALOBJ_MOD_ALL, NULL, async_remove_result_ready, NULL)) {
-		report_error ("remove object", &error);
-		g_free (uid);
-		stop_main_loop (1);
-		return FALSE;
-	}
+	e_cal_client_remove_object (cal_client, uid, NULL, CALOBJ_MOD_ALL, NULL, async_remove_result_ready, NULL);
 
 	g_free (uid);
 
diff --git a/tests/libecal/client/test-client-send-objects.c b/tests/libecal/client/test-client-send-objects.c
index 12332ce..1484853 100644
--- a/tests/libecal/client/test-client-send-objects.c
+++ b/tests/libecal/client/test-client-send-objects.c
@@ -92,7 +92,6 @@ static gboolean
 test_sync_in_idle (gpointer user_data)
 {
 	ECalClient *cal_client = user_data;
-	GError *error = NULL;
 	icalcomponent *icalcomp;
 
 	g_return_val_if_fail (cal_client != NULL, FALSE);
@@ -109,12 +108,7 @@ test_sync_in_idle (gpointer user_data)
 		return FALSE;
 	}
 
-	if (!e_cal_client_send_objects (cal_client, icalcomp, NULL, async_send_result_ready, NULL)) {
-		report_error ("send objects", &error);
-		icalcomponent_free (icalcomp);
-		stop_main_loop (1);
-		return FALSE;
-	}
+	e_cal_client_send_objects (cal_client, icalcomp, NULL, async_send_result_ready, NULL);
 
 	icalcomponent_free (icalcomp);
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]