From 1f9500479383fcd608cc7058a3cf5941c30ce35a Mon Sep 17 00:00:00 2001
From: Li Yuan
Date: Tue, 30 May 2006 07:01:07 +0000
Subject: Fix for #341381. We should lock e-tree-memory when we change it.
2006-05-30 Li Yuan
Fix for #341381.
* message-list.c: (message_list_set_folder):
We should lock e-tree-memory when we change it.
svn path=/trunk/; revision=32054
---
mail/ChangeLog | 6 ++++++
mail/message-list.c | 3 +++
2 files changed, 9 insertions(+)
diff --git a/mail/ChangeLog b/mail/ChangeLog
index b781937a0d..4db84b06ba 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,9 @@
+2006-05-30 Li Yuan
+
+ Fix for #341381.
+ * message-list.c: (message_list_set_folder):
+ We should lock e-tree-memory when we change it.
+
2006-05-30 Srinivasa Ragavan
** Fixes bug #332936
diff --git a/mail/message-list.c b/mail/message-list.c
index cef1a77e80..999fef410c 100644
--- a/mail/message-list.c
+++ b/mail/message-list.c
@@ -2827,6 +2827,7 @@ folder_changed (CamelObject *o, gpointer event_data, gpointer user_data)
void
message_list_set_folder (MessageList *message_list, CamelFolder *folder, const char *uri, gboolean outgoing)
{
+ ETreeModel *etm = message_list->model;
gboolean hide_deleted;
GConfClient *gconf;
CamelException ex;
@@ -2854,7 +2855,9 @@ message_list_set_folder (MessageList *message_list, CamelFolder *folder, const c
save_hide_state (message_list);
}
+ e_tree_memory_freeze(E_TREE_MEMORY(etm));
clear_tree (message_list);
+ e_tree_memory_thaw(E_TREE_MEMORY(etm));
if (message_list->folder) {
camel_object_unhook_event((CamelObject *)message_list->folder, "folder_changed",
--
cgit