Don't leak old sort info.

2002-12-03  Hans Petter Jansson  <hpj@ximian.com>

        * e-table.c (e_table_get_state_object): Don't leak old sort info.

2002-12-03  Hans Petter Jansson  <hpj@ximian.com>

        * gal/widgets/e-canvas-background.c (ecb_destroy): Don't leak
        private structure.

svn path=/trunk/; revision=18999
This commit is contained in:
Hans Petter Jansson
2002-12-03 23:09:17 +00:00
committed by Hans Petter
parent 6e5686598a
commit 200071108f
2 changed files with 7 additions and 0 deletions

View File

@ -177,6 +177,11 @@ ecb_dispose (GObject *object)
gdk_bitmap_unref (ecb->priv->stipple);
ecb->priv->stipple = NULL;
if (ecb->priv) {
g_free (ecb->priv);
ecb->priv = NULL;
}
if (G_OBJECT_CLASS (parent_class)->dispose)
G_OBJECT_CLASS (parent_class)->dispose (object);
}

View File

@ -1348,6 +1348,8 @@ e_table_get_state_object (ETable *e_table)
int i, j;
state = e_table_state_new();
if (state->sort_info)
g_object_unref (state->sort_info);
state->sort_info = e_table->sort_info;
g_object_ref(state->sort_info);