aboutsummaryrefslogtreecommitdiffstats
path: root/modules/addressbook/e-book-shell-view-actions.c
diff options
context:
space:
mode:
Diffstat (limited to 'modules/addressbook/e-book-shell-view-actions.c')
-rw-r--r--modules/addressbook/e-book-shell-view-actions.c25
1 files changed, 15 insertions, 10 deletions
diff --git a/modules/addressbook/e-book-shell-view-actions.c b/modules/addressbook/e-book-shell-view-actions.c
index d2fe86e0ca..125f3c36d6 100644
--- a/modules/addressbook/e-book-shell-view-actions.c
+++ b/modules/addressbook/e-book-shell-view-actions.c
@@ -212,17 +212,22 @@ address_book_refresh_done_cb (GObject *source_object,
client = E_CLIENT (source_object);
- if (!e_client_refresh_finish (client, result, &error)) {
- ESource *source = e_client_get_source (client);
+ e_client_refresh_finish (client, result, &error);
- if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED) &&
- !g_error_matches (error, E_CLIENT_ERROR, E_CLIENT_ERROR_CANCELLED))
- g_warning (
- "%s: Failed to refresh '%s', %s",
- G_STRFUNC, e_source_get_display_name (source),
- error ? error->message : "Unknown error");
+ if (g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED)) {
+ g_error_free (error);
+
+ } else if (error != NULL) {
+ ESource *source;
+
+ source = e_client_get_source (client);
- g_clear_error (&error);
+ g_warning (
+ "%s: Failed to refresh '%s', %s",
+ G_STRFUNC, e_source_get_display_name (source),
+ error ? error->message : "Unknown error");
+
+ g_error_free (error);
}
}
@@ -267,7 +272,7 @@ contact_editor_contact_modified_cb (EABEditor *editor,
EContactMap *map;
const gchar *contact_uid;
- if (error) {
+ if (error != NULL) {
g_warning ("Error modifying contact: %s", error->message);
return;
}