diff --git a/ChangeLog b/ChangeLog index 7547e34700..521699f90c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Wed Jul 21 21:26:08 2004 Matthias Clasen + + * gtk/gtkviewport.c (viewport_set_adjustment): Don't leak + the adjustments. (#148089, Tommi Komulainen) + Wed Jul 21 21:20:21 2004 Matthias Clasen * gtk/gtktreeview.c (gtk_tree_view_destroy): Don't leak diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index 7547e34700..521699f90c 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,8 @@ +Wed Jul 21 21:26:08 2004 Matthias Clasen + + * gtk/gtkviewport.c (viewport_set_adjustment): Don't leak + the adjustments. (#148089, Tommi Komulainen) + Wed Jul 21 21:20:21 2004 Matthias Clasen * gtk/gtktreeview.c (gtk_tree_view_destroy): Don't leak diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index 7547e34700..521699f90c 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,8 @@ +Wed Jul 21 21:26:08 2004 Matthias Clasen + + * gtk/gtkviewport.c (viewport_set_adjustment): Don't leak + the adjustments. (#148089, Tommi Komulainen) + Wed Jul 21 21:20:21 2004 Matthias Clasen * gtk/gtktreeview.c (gtk_tree_view_destroy): Don't leak diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index 7547e34700..521699f90c 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,8 @@ +Wed Jul 21 21:26:08 2004 Matthias Clasen + + * gtk/gtkviewport.c (viewport_set_adjustment): Don't leak + the adjustments. (#148089, Tommi Komulainen) + Wed Jul 21 21:20:21 2004 Matthias Clasen * gtk/gtktreeview.c (gtk_tree_view_destroy): Don't leak diff --git a/gtk/gtkviewport.c b/gtk/gtkviewport.c index 397f200b31..9969c0a0d1 100644 --- a/gtk/gtkviewport.c +++ b/gtk/gtkviewport.c @@ -462,7 +462,8 @@ viewport_set_adjustment (GtkViewport *viewport, if (!adjustment) adjustment = GTK_ADJUSTMENT (gtk_adjustment_new (0.0, 0.0, 0.0, 0.0, 0.0, 0.0)); - + if (*adjustmentp) + g_object_unref (*adjustmentp); *adjustmentp = adjustment; g_object_ref (adjustment); gtk_object_sink (GTK_OBJECT (adjustment));