From 2777802f60e8de91ea9dd454e411372f4078bf0f Mon Sep 17 00:00:00 2001 From: Veerapuram Varadhan Date: Wed, 26 Jul 2006 13:19:18 +0000 Subject: ** Fixes bgo bug #333821 and bnc bug 181851 * mail-folder-cache.c: (ping_store_ping): Ping store only iff store is online and connected. svn path=/trunk/; revision=32419 --- mail/ChangeLog | 7 +++++++ mail/mail-folder-cache.c | 11 ++++++++++- 2 files changed, 17 insertions(+), 1 deletion(-) (limited to 'mail') diff --git a/mail/ChangeLog b/mail/ChangeLog index c3e443f4a0..2739f1e006 100644 --- a/mail/ChangeLog +++ b/mail/ChangeLog @@ -1,3 +1,10 @@ +2006-07-26 Veerapuram Varadhan + + ** Fixes bgo bug #333821 and bnc bug 181851 + + * mail-folder-cache.c: (ping_store_ping): Ping store only iff + store is online and connected. + 2006-07-26 Arvind ** Fix for bug #274276 diff --git a/mail/mail-folder-cache.c b/mail/mail-folder-cache.c index 53e42512c0..598141657e 100644 --- a/mail/mail-folder-cache.c +++ b/mail/mail-folder-cache.c @@ -864,9 +864,18 @@ ping_store_desc (struct _mail_msg *mm, int done) static void ping_store_ping (struct _mail_msg *mm) { + gboolean online = FALSE; struct _ping_store_msg *m = (struct _ping_store_msg *) mm; - if (CAMEL_SERVICE (m->store)->status == CAMEL_SERVICE_CONNECTED) + if (CAMEL_SERVICE (m->store)->status == CAMEL_SERVICE_CONNECTED) { + if (CAMEL_IS_DISCO_STORE (m->store) && + camel_disco_store_status (CAMEL_DISCO_STORE (m->store)) != CAMEL_DISCO_STORE_OFFLINE) + online = TRUE; + else if (CAMEL_IS_OFFLINE_STORE (m->store) && + CAMEL_OFFLINE_STORE (m->store)->state != CAMEL_OFFLINE_STORE_NETWORK_UNAVAIL) + online = TRUE; + } + if (online) camel_store_noop (m->store, &mm->ex); } -- cgit