diff options
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | ChangeLog.pre-2-0 | 6 | ||||
-rw-r--r-- | ChangeLog.pre-2-10 | 6 | ||||
-rw-r--r-- | ChangeLog.pre-2-2 | 6 | ||||
-rw-r--r-- | ChangeLog.pre-2-4 | 6 | ||||
-rw-r--r-- | ChangeLog.pre-2-6 | 6 | ||||
-rw-r--r-- | ChangeLog.pre-2-8 | 6 | ||||
-rw-r--r-- | gtk/gtkcalendar.c | 16 |
8 files changed, 52 insertions, 6 deletions
@@ -1,3 +1,9 @@ +2002-02-10 Anders Carlsson <andersca@gnu.org> + + * gtk/gtkcalendar.c (gtk_calendar_class_init): Set finalize handler; + (gtk_calendar_finalize): Rename gtk_calendar_destroy to gtk_calendar_finalize + since ::destroy can be called multiple times, resulting in double-freeing memory. + 2002-02-10 Hans Breuer <hans@breuer.org> * gdk/win32/gdkgeometry-win32.c : don't reduce the scroll diff --git a/ChangeLog.pre-2-0 b/ChangeLog.pre-2-0 index 9e55008909..bf10eb4e2e 100644 --- a/ChangeLog.pre-2-0 +++ b/ChangeLog.pre-2-0 @@ -1,3 +1,9 @@ +2002-02-10 Anders Carlsson <andersca@gnu.org> + + * gtk/gtkcalendar.c (gtk_calendar_class_init): Set finalize handler; + (gtk_calendar_finalize): Rename gtk_calendar_destroy to gtk_calendar_finalize + since ::destroy can be called multiple times, resulting in double-freeing memory. + 2002-02-10 Hans Breuer <hans@breuer.org> * gdk/win32/gdkgeometry-win32.c : don't reduce the scroll diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index 9e55008909..bf10eb4e2e 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,9 @@ +2002-02-10 Anders Carlsson <andersca@gnu.org> + + * gtk/gtkcalendar.c (gtk_calendar_class_init): Set finalize handler; + (gtk_calendar_finalize): Rename gtk_calendar_destroy to gtk_calendar_finalize + since ::destroy can be called multiple times, resulting in double-freeing memory. + 2002-02-10 Hans Breuer <hans@breuer.org> * gdk/win32/gdkgeometry-win32.c : don't reduce the scroll diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2 index 9e55008909..bf10eb4e2e 100644 --- a/ChangeLog.pre-2-2 +++ b/ChangeLog.pre-2-2 @@ -1,3 +1,9 @@ +2002-02-10 Anders Carlsson <andersca@gnu.org> + + * gtk/gtkcalendar.c (gtk_calendar_class_init): Set finalize handler; + (gtk_calendar_finalize): Rename gtk_calendar_destroy to gtk_calendar_finalize + since ::destroy can be called multiple times, resulting in double-freeing memory. + 2002-02-10 Hans Breuer <hans@breuer.org> * gdk/win32/gdkgeometry-win32.c : don't reduce the scroll diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index 9e55008909..bf10eb4e2e 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -1,3 +1,9 @@ +2002-02-10 Anders Carlsson <andersca@gnu.org> + + * gtk/gtkcalendar.c (gtk_calendar_class_init): Set finalize handler; + (gtk_calendar_finalize): Rename gtk_calendar_destroy to gtk_calendar_finalize + since ::destroy can be called multiple times, resulting in double-freeing memory. + 2002-02-10 Hans Breuer <hans@breuer.org> * gdk/win32/gdkgeometry-win32.c : don't reduce the scroll diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index 9e55008909..bf10eb4e2e 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,9 @@ +2002-02-10 Anders Carlsson <andersca@gnu.org> + + * gtk/gtkcalendar.c (gtk_calendar_class_init): Set finalize handler; + (gtk_calendar_finalize): Rename gtk_calendar_destroy to gtk_calendar_finalize + since ::destroy can be called multiple times, resulting in double-freeing memory. + 2002-02-10 Hans Breuer <hans@breuer.org> * gdk/win32/gdkgeometry-win32.c : don't reduce the scroll diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index 9e55008909..bf10eb4e2e 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,9 @@ +2002-02-10 Anders Carlsson <andersca@gnu.org> + + * gtk/gtkcalendar.c (gtk_calendar_class_init): Set finalize handler; + (gtk_calendar_finalize): Rename gtk_calendar_destroy to gtk_calendar_finalize + since ::destroy can be called multiple times, resulting in double-freeing memory. + 2002-02-10 Hans Breuer <hans@breuer.org> * gdk/win32/gdkgeometry-win32.c : don't reduce the scroll diff --git a/gtk/gtkcalendar.c b/gtk/gtkcalendar.c index cb5d51ae7b..ff2fb029c9 100644 --- a/gtk/gtkcalendar.c +++ b/gtk/gtkcalendar.c @@ -258,7 +258,7 @@ typedef void (*GtkCalendarSignalDate) (GtkObject *object, guint arg1, guint arg2 static void gtk_calendar_class_init (GtkCalendarClass *class); static void gtk_calendar_init (GtkCalendar *calendar); -static void gtk_calendar_destroy (GtkObject *calendar); +static void gtk_calendar_finalize (GObject *calendar); static void gtk_calendar_realize (GtkWidget *widget); static void gtk_calendar_unrealize (GtkWidget *widget); static void gtk_calendar_size_request (GtkWidget *widget, @@ -334,15 +334,17 @@ gtk_calendar_get_type (void) static void gtk_calendar_class_init (GtkCalendarClass *class) { + GObjectClass *gobject_class; GtkObjectClass *object_class; GtkWidgetClass *widget_class; - + + gobject_class = (GObjectClass*) class; object_class = (GtkObjectClass*) class; widget_class = (GtkWidgetClass*) class; parent_class = gtk_type_class (GTK_TYPE_WIDGET); - object_class->destroy = gtk_calendar_destroy; + gobject_class->finalize = gtk_calendar_finalize; widget_class->realize = gtk_calendar_realize; widget_class->unrealize = gtk_calendar_unrealize; @@ -2495,13 +2497,15 @@ gtk_calendar_state_changed (GtkWidget *widget, } static void -gtk_calendar_destroy (GtkObject *object) +gtk_calendar_finalize (GObject *object) { GtkCalendarPrivateData *private_data; private_data = GTK_CALENDAR_PRIVATE_DATA (object); + g_free (private_data); - if (GTK_OBJECT_CLASS (parent_class)->destroy) - (* GTK_OBJECT_CLASS (parent_class)->destroy) (object); + + if (G_OBJECT_CLASS (parent_class)->finalize) + (* G_OBJECT_CLASS (parent_class)->finalize) (object); } static gboolean |