[evolution-mapi] Bug #620095 - Deadlock while filling folder list in Contacts



commit 782dc90964a386498243897e86c431785c06cbd7
Author: Oded Arbel <oded geek co il>
Date:   Mon May 31 20:15:40 2010 +0200

    Bug #620095 - Deadlock while filling folder list in Contacts

 .../exchange-mapi-account-setup.c                  |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)
---
diff --git a/src/account-setup-eplugin/exchange-mapi-account-setup.c b/src/account-setup-eplugin/exchange-mapi-account-setup.c
index b23674d..829fc82 100644
--- a/src/account-setup-eplugin/exchange-mapi-account-setup.c
+++ b/src/account-setup-eplugin/exchange-mapi-account-setup.c
@@ -435,7 +435,6 @@ check_node (GtkTreeStore *ts, ExchangeMAPIFolder *folder, GtkTreeIter iter)
 {
 	GtkTreeModel *ts_model;
 	mapi_id_t fid;
-	gboolean status = FALSE;
 
 	ts_model = GTK_TREE_MODEL (ts);
 
@@ -451,14 +450,15 @@ check_node (GtkTreeStore *ts, ExchangeMAPIFolder *folder, GtkTreeIter iter)
 	if (gtk_tree_model_iter_has_child (ts_model, &iter)) {
 		GtkTreeIter child;
 		gtk_tree_model_iter_children (ts_model, &child, &iter);
-		status = check_node (ts, folder, child);
+		if (check_node (ts, folder, child))
+		    return TRUE;
 	}
 
-	while (gtk_tree_model_iter_next (ts_model, &iter) && !status) {
-		status = check_node (ts, folder, iter);
+	if (gtk_tree_model_iter_next (ts_model, &iter)) {
+		return check_node (ts, folder, iter);
 	}
 
-	return status;
+	return FALSE;
 }
 
 static void



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