diff options
author | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2006-01-12 10:15:27 +0000 |
---|---|---|
committer | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2006-01-12 10:15:27 +0000 |
commit | c505586c9e396225a26f2325fdde54162ecf54bb (patch) | |
tree | 30bda8ed560d022e123b9e8716a79828945808a2 | |
parent | 7453f17c71180722d11c29ee987d5ca5f2536e2b (diff) |
fixed a memory leak where threading is off.
git-svn-id: svn://sylpheed.sraoss.jp/sylpheed/trunk@894 ee746299-78ed-0310-b773-934348b2243d
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | ChangeLog.ja | 5 | ||||
-rw-r--r-- | src/summaryview.c | 7 |
3 files changed, 14 insertions, 3 deletions
@@ -1,5 +1,10 @@ 2006-01-12 + * src/summaryview.c: summary_set_tree_model_from_list(): fixed a + memory leak where threading is off. + +2006-01-12 + * libsylph/virtual.c: virtual_rename_folder(): added. * src/folderview.c: folderview_rename_folder_cb(): fixed renaming of virtual folders. diff --git a/ChangeLog.ja b/ChangeLog.ja index 2e99e50d..ba16074d 100644 --- a/ChangeLog.ja +++ b/ChangeLog.ja @@ -1,5 +1,10 @@ 2006-01-12 + * src/summaryview.c: summary_set_tree_model_from_list(): スレッド表示 + が off の場合のメモリリークを修正。 + +2006-01-12 + * libsylph/virtual.c: virtual_rename_folder(): 追加。 * src/folderview.c: folderview_rename_folder_cb(): 仮想フォルダの 名前変更を修正。 diff --git a/src/summaryview.c b/src/summaryview.c index a0f4f5e7..f6542ec4 100644 --- a/src/summaryview.c +++ b/src/summaryview.c @@ -2099,10 +2099,11 @@ static void summary_set_tree_model_from_list(SummaryView *summaryview, summaryview->total_size += msginfo->size; } } else { + GSList *rev_mlist; GtkTreeIter iter; - mlist = g_slist_reverse(mlist); - for (cur = mlist; cur != NULL; cur = cur->next) { + rev_mlist = g_slist_reverse(g_slist_copy(mlist)); + for (cur = rev_mlist; cur != NULL; cur = cur->next) { msginfo = (MsgInfo *)cur->data; gtk_tree_store_prepend(store, &iter, NULL); @@ -2112,7 +2113,7 @@ static void summary_set_tree_model_from_list(SummaryView *summaryview, summaryview->deleted++; summaryview->total_size += msginfo->size; } - /* mlist = g_slist_reverse(mlist); */ + g_slist_free(rev_mlist); } gtk_tree_view_set_model(GTK_TREE_VIEW(summaryview->treeview), |