diff options
author | Not Zed <NotZed@HelixCode.com> | 2000-11-17 14:18:01 +0800 |
---|---|---|
committer | Michael Zucci <zucchi@src.gnome.org> | 2000-11-17 14:18:01 +0800 |
commit | 25107cd4d712e05a366ccf772ed0ca40aaaecaa9 (patch) | |
tree | 3481308d2797480f0addcf618cf3f15da29d5b91 /mail/message-list.c | |
parent | a1ccc43fbe30d1e68a668accf9759a19edec2d96 (diff) | |
download | gsoc2013-evolution-25107cd4d712e05a366ccf772ed0ca40aaaecaa9.tar.gz gsoc2013-evolution-25107cd4d712e05a366ccf772ed0ca40aaaecaa9.tar.zst gsoc2013-evolution-25107cd4d712e05a366ccf772ed0ca40aaaecaa9.zip |
Before we destroy ourselves, unhook ourselves from the folder update
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.
svn path=/trunk/; revision=6598
Diffstat (limited to 'mail/message-list.c')
-rw-r--r-- | mail/message-list.c | 10 |
1 files changed, 9 insertions, 1 deletions
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); } |