aboutsummaryrefslogtreecommitdiffstats
path: root/modules/mail
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2013-09-08 00:31:19 +0800
committerMatthew Barnes <mbarnes@redhat.com>2013-09-08 07:08:54 +0800
commit3da4948c0fc1f2c21b163f0ec456b2d99c881258 (patch)
tree479d6153d31e03cb7a65990683b5271402e5ec29 /modules/mail
parent2e5031cb4538b4819e5fce5d717668c3445df80a (diff)
downloadgsoc2013-evolution-3da4948c0fc1f2c21b163f0ec456b2d99c881258.tar
gsoc2013-evolution-3da4948c0fc1f2c21b163f0ec456b2d99c881258.tar.gz
gsoc2013-evolution-3da4948c0fc1f2c21b163f0ec456b2d99c881258.tar.bz2
gsoc2013-evolution-3da4948c0fc1f2c21b163f0ec456b2d99c881258.tar.lz
gsoc2013-evolution-3da4948c0fc1f2c21b163f0ec456b2d99c881258.tar.xz
gsoc2013-evolution-3da4948c0fc1f2c21b163f0ec456b2d99c881258.tar.zst
gsoc2013-evolution-3da4948c0fc1f2c21b163f0ec456b2d99c881258.zip
Miscellaneous cleanups.
Diffstat (limited to 'modules/mail')
-rw-r--r--modules/mail/e-mail-shell-view-actions.c24
1 files changed, 14 insertions, 10 deletions
diff --git a/modules/mail/e-mail-shell-view-actions.c b/modules/mail/e-mail-shell-view-actions.c
index e451574ecf..a0191effa3 100644
--- a/modules/mail/e-mail-shell-view-actions.c
+++ b/modules/mail/e-mail-shell-view-actions.c
@@ -112,21 +112,25 @@ account_refresh_folder_info_received_cb (GObject *source,
GError *error = NULL;
store = CAMEL_STORE (source);
- activity = user_data;
+ activity = E_ACTIVITY (user_data);
+
info = camel_store_get_folder_info_finish (store, result, &error);
- if (info) {
- /* provider takes care of notifications of new/removed folders,
- * thus it's enough to free the returned list */
+
+ if (info != NULL) {
+ /* Provider takes care of notifications of new/removed
+ * folders, thus it's enough to free the returned list. */
camel_store_free_folder_info (store, info);
}
- if (error && !g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED))
- g_message ("%s: Failed: %s", G_STRFUNC, error->message);
+ if (e_activity_handle_cancellation (activity, error)) {
+ g_error_free (error);
- g_clear_error (&error);
+ } else if (error != NULL) {
+ g_warning ("%s: %s", G_STRFUNC, error->message);
+ g_error_free (error);
+ }
- if (activity)
- g_object_unref (activity);
+ g_clear_object (&activity);
}
static void
@@ -458,7 +462,7 @@ mark_all_read_thread (GSimpleAsyncResult *simple,
g_object_unref (folder);
}
- if (error)
+ if (error != NULL)
g_simple_async_result_take_error (simple, error);
}