Commit f1897b65 authored by Michael Natterer's avatar Michael Natterer 😴

app: free Gimp members in reverse order of creation

parent 7f3090fe
......@@ -341,6 +341,26 @@ gimp_dispose (GObject *object)
gimp_filter_history_clear (gimp);
if (gimp->edit_config)
{
g_object_unref (gimp->edit_config);
gimp->edit_config = NULL;
}
if (gimp->config)
{
g_object_unref (gimp->config);
gimp->config = NULL;
}
gimp_contexts_exit (gimp);
if (gimp->image_new_last_template)
{
g_object_unref (gimp->image_new_last_template);
gimp->image_new_last_template = NULL;
}
G_OBJECT_CLASS (parent_class)->dispose (object);
}
......@@ -366,14 +386,6 @@ gimp_finalize (GObject *object)
standards = g_list_prepend (standards,
gimp_palette_get_standard (gimp->user_context));
gimp_contexts_exit (gimp);
if (gimp->image_new_last_template)
{
g_object_unref (gimp->image_new_last_template);
gimp->image_new_last_template = NULL;
}
if (gimp->templates)
{
g_object_unref (gimp->templates);
......@@ -461,12 +473,6 @@ gimp_finalize (GObject *object)
gimp->parasites = NULL;
}
if (gimp->edit_config)
{
g_object_unref (gimp->edit_config);
gimp->edit_config = NULL;
}
if (gimp->default_folder)
{
g_object_unref (gimp->default_folder);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment