[evolution/gnome-3-26] Bug 785618 - Unread mail count in IMAP folder not always updated
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution/gnome-3-26] Bug 785618 - Unread mail count in IMAP folder not always updated
- Date: Tue, 12 Sep 2017 16:59:46 +0000 (UTC)
commit 92cc8b127a25690bb881a28ccbdbd3b9b025217c
Author: Milan Crha <mcrha redhat com>
Date: Tue Sep 12 18:48:50 2017 +0200
Bug 785618 - Unread mail count in IMAP folder not always updated
src/libemail-engine/mail-folder-cache.c | 18 ++++++------------
1 files changed, 6 insertions(+), 12 deletions(-)
---
diff --git a/src/libemail-engine/mail-folder-cache.c b/src/libemail-engine/mail-folder-cache.c
index cfe0503..7282615 100644
--- a/src/libemail-engine/mail-folder-cache.c
+++ b/src/libemail-engine/mail-folder-cache.c
@@ -2092,20 +2092,14 @@ mail_folder_cache_note_store_thread (GSimpleAsyncResult *simple,
}
if (!store_online) {
- e_mail_store_go_online_sync (
- CAMEL_STORE (service),
- cancellable, &local_error);
-
- if (local_error != NULL) {
- g_simple_async_result_take_error (
- simple, local_error);
- goto exit;
- }
+ /* Ignore these errors, it can still provide folders in offline */
+ store_online = e_mail_store_go_online_sync (CAMEL_STORE (service), cancellable, NULL);
}
- if (!mail_folder_cache_maybe_run_initial_setup_sync (service, cancellable, &local_error)) {
- g_simple_async_result_take_error (simple, local_error);
- goto exit;
+ if (store_online && !mail_folder_cache_maybe_run_initial_setup_sync (service, cancellable,
&local_error)) {
+ /* Just log on console, but keep going otherwise */
+ g_warning ("%s: Failed to run initial setup for '%s': %s", G_STRFUNC,
camel_service_get_display_name (service), local_error ? local_error->message : "Unknown error");
+ g_clear_error (&local_error);
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]