From ba5b1b6be7d3beed85c1f6b51d5808f9a7d72b5f Mon Sep 17 00:00:00 2001 From: 5 Date: Tue, 25 Sep 2001 22:18:52 +0000 Subject: Deal with destroy vs finalise semantics. Only destroy widgets here. 2001-09-25 * folder-browser.c (folder_browser_destroy): Deal with destroy vs finalise semantics. Only destroy widgets here. (folder_browser_finalise): object finalise function, actually unref/free all other objects here. (folder_browser_class_init): Init the finalise hook. (got_folder): Check if message_list == NULL -> we've been destroyed before the thread got a chance to finish loading the folder. (folder_browser_is_drafts): Dont use a g_return_if_fail to return in what could be a valid state of the object. (folder_browser_is_sent): Likewise. (folder_browser_copy): Do nothing if message_list == NULL. * main.c (main): call mail_msg_cleanup() before leaving threads. * component-factory.c (owner_unset_cb): Wait for all outstanding operations to finish before setting up to quit. (idle_quit): Wait for all outstanding ops to finish before cleanup. (unref_standard_folders): NULL out the standard folder before unreffing it. * mail-mt.c (mail_msg_wait_all): New function to wait for all outstanding thread operations. (mail_msg_cleanup): Destroy the io channels before we're finished. Also wait for all outstanding threads first. Made public. (mail_msg_init): Dont call mail_msg_cleanup atexit automatically. svn path=/trunk/; revision=13129 --- mail/main.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'mail/main.c') diff --git a/mail/main.c b/mail/main.c index 41a9482167..dc2042f19b 100644 --- a/mail/main.c +++ b/mail/main.c @@ -139,6 +139,9 @@ main (int argc, char *argv []) GDK_THREADS_ENTER (); bonobo_main (); + + mail_msg_cleanup(); + GDK_THREADS_LEAVE (); mail_config_write_on_exit (); -- cgit v1.2.3