diff options
author | Jeffrey Stedfast <fejj@ximian.com> | 2001-08-10 13:24:43 +0800 |
---|---|---|
committer | Jeffrey Stedfast <fejj@src.gnome.org> | 2001-08-10 13:24:43 +0800 |
commit | d9ae7c3b78cd10b9fec1ee8bf972cf05e319d968 (patch) | |
tree | 7e495f5fd80fc2fecb62971211e2c6c574ad159b /mail | |
parent | 513bfe0292c1721708e83617a8b19db3574060fb (diff) | |
download | gsoc2013-evolution-d9ae7c3b78cd10b9fec1ee8bf972cf05e319d968.tar gsoc2013-evolution-d9ae7c3b78cd10b9fec1ee8bf972cf05e319d968.tar.gz gsoc2013-evolution-d9ae7c3b78cd10b9fec1ee8bf972cf05e319d968.tar.bz2 gsoc2013-evolution-d9ae7c3b78cd10b9fec1ee8bf972cf05e319d968.tar.lz gsoc2013-evolution-d9ae7c3b78cd10b9fec1ee8bf972cf05e319d968.tar.xz gsoc2013-evolution-d9ae7c3b78cd10b9fec1ee8bf972cf05e319d968.tar.zst gsoc2013-evolution-d9ae7c3b78cd10b9fec1ee8bf972cf05e319d968.zip |
Free dbkey if we don't use it.
2001-08-10 Jeffrey Stedfast <fejj@ximian.com>
* mail-config.c (mail_config_get_show_preview): Free dbkey if we
don't use it.
* folder-browser.c (on_right_click): Added a comment about leaking
memory here, but we seem to not even use the 2 strings we
strdup...is this code still under construction?
* mail-ops.c (mail_send_message): Free the sent_folder_uri at the
bottom of the function (ironically enough we were freeing it if we
encountered an error but never free'd it on success :-)
(get_folderinfo_got): Fixed a memory leak...this one would have
gone away once we got rid of the debug g_warning though.
svn path=/trunk/; revision=11874
Diffstat (limited to 'mail')
-rw-r--r-- | mail/ChangeLog | 3 | ||||
-rw-r--r-- | mail/mail-config.c | 4 | ||||
-rw-r--r-- | mail/message-list.c | 32 |
3 files changed, 22 insertions, 17 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog index 8724f3f6d8..778273d447 100644 --- a/mail/ChangeLog +++ b/mail/ChangeLog @@ -1,5 +1,8 @@ 2001-08-10 Jeffrey Stedfast <fejj@ximian.com> + * mail-config.c (mail_config_get_show_preview): Free dbkey if we + don't use it. + * folder-browser.c (on_right_click): Added a comment about leaking memory here, but we seem to not even use the 2 strings we strdup...is this code still under construction? diff --git a/mail/mail-config.c b/mail/mail-config.c index 48507f36b0..e65317edca 100644 --- a/mail/mail-config.c +++ b/mail/mail-config.c @@ -920,8 +920,10 @@ mail_config_get_show_preview (const char *uri) GINT_TO_POINTER (value)); return value; - } else + } else { + g_free (dbkey); return GPOINTER_TO_INT (val); + } } /* return the default value */ diff --git a/mail/message-list.c b/mail/message-list.c index c9bbcf2980..64c65404a7 100644 --- a/mail/message-list.c +++ b/mail/message-list.c @@ -1032,7 +1032,7 @@ sort_info_changed (GtkWidget *widget, MessageList *ml) } static void -message_list_setup_etree(MessageList *message_list, gboolean outgoing) +message_list_setup_etree (MessageList *message_list, gboolean outgoing) { ETableState *etstate; @@ -1044,8 +1044,8 @@ message_list_setup_etree(MessageList *message_list, gboolean outgoing) struct stat st; name = camel_service_get_name (CAMEL_SERVICE (message_list->folder->parent_store), TRUE); - printf ("folder name is '%s'\n", name); - + d(printf ("folder name is '%s'\n", name)); + path = mail_config_folder_to_cachename (message_list->folder, "et-header-"); if (path && stat (path, &st) == 0 && st.st_size > 0 && S_ISREG (st.st_mode)) { /* build based on saved file */ @@ -1067,20 +1067,20 @@ message_list_setup_etree(MessageList *message_list, gboolean outgoing) e_tree_load_expanded_state (message_list->tree, path); } g_free (path); - + g_free (name); - - etstate = e_tree_get_state_object(message_list->tree); - gtk_signal_connect(GTK_OBJECT(etstate->sort_info), - "sort_info_changed", - GTK_SIGNAL_FUNC(sort_info_changed), - message_list); - gtk_signal_connect(GTK_OBJECT(etstate->sort_info), - "group_info_changed", - GTK_SIGNAL_FUNC(sort_info_changed), - message_list); - - gtk_object_unref((GtkObject *)etstate); + + etstate = e_tree_get_state_object (message_list->tree); + gtk_signal_connect (GTK_OBJECT (etstate->sort_info), + "sort_info_changed", + GTK_SIGNAL_FUNC (sort_info_changed), + message_list); + gtk_signal_connect (GTK_OBJECT (etstate->sort_info), + "group_info_changed", + GTK_SIGNAL_FUNC (sort_info_changed), + message_list); + + gtk_object_unref (GTK_OBJECT (etstate)); } } |