[evolution-data-server/gnome-2-32] Bug #615828 - Incorrectly set off-line state on CamelOfflineStore



commit 1869d10790ce7f4896084098de7da78ca55750f5
Author: Milan Crha <mcrha redhat com>
Date:   Thu Sep 30 14:06:33 2010 +0200

    Bug #615828 - Incorrectly set off-line state on CamelOfflineStore

 camel/camel-offline-store.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/camel/camel-offline-store.c b/camel/camel-offline-store.c
index aefd401..9a3200b 100644
--- a/camel/camel-offline-store.c
+++ b/camel/camel-offline-store.c
@@ -138,13 +138,14 @@ camel_offline_store_set_network_state (CamelOfflineStore *store,
 			camel_store_sync (CAMEL_STORE (store), FALSE, NULL);
 		}
 
-		if (!camel_service_disconnect (CAMEL_SERVICE (store), network_available, error))
+		if (!camel_service_disconnect (CAMEL_SERVICE (store), network_available, error)) {
+			store->state = state;
 			return FALSE;
+		}
 	} else {
 		store->state = state;
 		/* network unavailable -> network available */
 		if (!camel_service_connect (CAMEL_SERVICE (store), error)) {
-			store->state = CAMEL_OFFLINE_STORE_NETWORK_UNAVAIL;
 			return FALSE;
 		}
 	}



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