[gimp] Fix finalize() so it doesn't crash
- From: Michael Natterer <mitch src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gimp] Fix finalize() so it doesn't crash
- Date: Mon, 24 Aug 2009 15:31:05 +0000 (UTC)
commit c8c6d77c3584c306de4d00a526df488d87e4c027
Author: Michael Natterer <mitch gimp org>
Date: Mon Aug 24 17:30:41 2009 +0200
Fix finalize() so it doesn't crash
app/core/gimpgrouplayer.c | 15 +++++++++------
1 files changed, 9 insertions(+), 6 deletions(-)
---
diff --git a/app/core/gimpgrouplayer.c b/app/core/gimpgrouplayer.c
index 6e1d5e3..e879f87 100644
--- a/app/core/gimpgrouplayer.c
+++ b/app/core/gimpgrouplayer.c
@@ -227,12 +227,6 @@ gimp_group_layer_finalize (GObject *object)
{
GimpGroupLayer *group = GIMP_GROUP_LAYER (object);
- if (group->projection)
- {
- g_object_unref (group->projection);
- group->projection = NULL;
- }
-
if (group->children)
{
g_signal_handlers_disconnect_by_func (group->children,
@@ -241,11 +235,20 @@ gimp_group_layer_finalize (GObject *object)
g_signal_handlers_disconnect_by_func (group->children,
gimp_group_layer_child_remove,
group);
+ g_signal_handlers_disconnect_by_func (group->children,
+ gimp_group_layer_stack_update,
+ group);
g_object_unref (group->children);
group->children = NULL;
}
+ if (group->projection)
+ {
+ g_object_unref (group->projection);
+ group->projection = NULL;
+ }
+
G_OBJECT_CLASS (parent_class)->finalize (object);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]