[evolution-ews/gnome-2-28] Fix a critical warning crasher



commit 735ec47b185c29506bf99719339555a84b46656f
Author: Chenthill Palanisamy <pchenthill novell com>
Date:   Thu Dec 15 12:53:58 2011 +0530

    Fix a critical warning crasher

 src/camel/camel-ews-store.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/src/camel/camel-ews-store.c b/src/camel/camel-ews-store.c
index 9679dca..203d587 100644
--- a/src/camel/camel-ews-store.c
+++ b/src/camel/camel-ews-store.c
@@ -310,8 +310,10 @@ ews_disconnect_sync (CamelService *service, gboolean clean, EVO3(GCancellable *c
 	camel_service_lock (service, CAMEL_SERVICE_REC_CONNECT_LOCK);
 
 	/* TODO cancel all operations in the connection */
-	g_object_unref (ews_store->priv->cnc);
-	ews_store->priv->cnc = NULL;
+	if (ews_store->priv->cnc) {
+		g_object_unref (ews_store->priv->cnc);
+		ews_store->priv->cnc = NULL;
+	}
 
 	camel_service_unlock (service, CAMEL_SERVICE_REC_CONNECT_LOCK);
 



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