diff options
-rw-r--r-- | calendar/ChangeLog | 9 | ||||
-rw-r--r-- | calendar/gui/calendar-component.c | 16 |
2 files changed, 19 insertions, 6 deletions
diff --git a/calendar/ChangeLog b/calendar/ChangeLog index d394011bd4..8f64ada556 100644 --- a/calendar/ChangeLog +++ b/calendar/ChangeLog @@ -1,3 +1,12 @@ +2007-08-06 Milan Crha <mcrha@redhat.com> + + ** Fix for bug #463129 + + * gui/calendar-component.c: (update_task_memo_selection), + (destroy_component_view): Frees task_source_selection and + memo_source_selection in destroy_component_view instead of + immediately after assigning it to the structure. + 2007-08-06 Srinivasa Ragavan <sragavan@novell.com> ** Fix for bug #454253 diff --git a/calendar/gui/calendar-component.c b/calendar/gui/calendar-component.c index 95292cd0a9..ab445b03d6 100644 --- a/calendar/gui/calendar-component.c +++ b/calendar/gui/calendar-component.c @@ -438,7 +438,6 @@ update_task_memo_selection (CalendarComponentView *component_view, ECalSourceTyp uids_selected = calendar_config_get_tasks_selected (); source_list = component_view->task_source_list; source_selection = component_view->task_source_selection; - } else { uids_selected = calendar_config_get_memos_selected (); source_list = component_view->memo_source_list; @@ -474,11 +473,6 @@ update_task_memo_selection (CalendarComponentView *component_view, ECalSourceTyp component_view->task_source_selection = uids_selected; else component_view->memo_source_selection = uids_selected; - - if (uids_selected) { - g_slist_foreach (uids_selected, (GFunc) g_free, NULL); - g_slist_free (uids_selected); - } } static void @@ -1505,6 +1499,16 @@ destroy_component_view (CalendarComponentView *component_view) if (component_view->activity_handler) g_object_unref (component_view->activity_handler); + if (component_view->task_source_selection) { + g_slist_foreach (component_view->task_source_selection, (GFunc) g_free, NULL); + g_slist_free (component_view->task_source_selection); + } + + if (component_view->memo_source_selection) { + g_slist_foreach (component_view->memo_source_selection, (GFunc) g_free, NULL); + g_slist_free (component_view->memo_source_selection); + } + g_free (component_view); } |