diff options
Diffstat (limited to 'mail')
-rw-r--r-- | mail/ChangeLog | 6 | ||||
-rw-r--r-- | mail/message-list.c | 10 |
2 files changed, 15 insertions, 1 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog index a39cc0bfd2..b73815fd03 100644 --- a/mail/ChangeLog +++ b/mail/ChangeLog @@ -1,3 +1,9 @@ +2000-11-17 Not Zed <NotZed@HelixCode.com> + + * message-list.c (message_list_destroy): Before we destroy + ourselves, unhook ourselves from the folder update events. Should + fix a common crash on exit case. + 2000-11-16 Jeffrey Stedfast <fejj@helixcode.com> * folder-browser-factory.c: Added the MessageViewSource bonobo diff --git a/mail/message-list.c b/mail/message-list.c index 685bfa6be0..6fc97de969 100644 --- a/mail/message-list.c +++ b/mail/message-list.c @@ -91,6 +91,9 @@ static void free_tree_ids (ETreeModel *etm); static void save_tree_state(MessageList *ml); +static void folder_changed (CamelObject *o, gpointer event_data, gpointer user_data); +static void message_changed (CamelObject *o, gpointer event_data, gpointer user_data); + /* note: @changes is owned/freed by the caller */ static void mail_do_regenerate_messagelist (MessageList *list, const gchar *search, CamelFolderChangeInfo *changes); @@ -1050,8 +1053,13 @@ message_list_destroy (GtkObject *object) if (message_list->seen_id) gtk_timeout_remove (message_list->seen_id); - if (message_list->folder) + if (message_list->folder) { + camel_object_unhook_event((CamelObject *)message_list->folder, "folder_changed", + folder_changed, message_list); + camel_object_unhook_event((CamelObject *)message_list->folder, "message_changed", + message_changed, message_list); camel_object_unref (CAMEL_OBJECT (message_list->folder)); + } GTK_OBJECT_CLASS (message_list_parent_class)->destroy (object); } |