From 54139b8806d67ba3b2b97629ab0efc28654cf866 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Sat, 8 Sep 2007 05:23:12 +0000 Subject: [PATCH] Use g_slice for ToolbarContent. (#474696, Christian Persch) 2007-09-07 Matthias Clasen * gtk/gtktoolbar.c: Use g_slice for ToolbarContent. (#474696, Christian Persch) svn path=/trunk/; revision=18760 --- ChangeLog | 5 +++++ gtk/gtktoolbar.c | 6 +++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 259cfa2649..785b782d6b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2007-09-07 Matthias Clasen + + * gtk/gtktoolbar.c: Use g_slice for ToolbarContent. + (#474696, Christian Persch) + 2007-09-07 Matthias Clasen * gtk/gtkprintunixdialog.c: Add an internal child name for diff --git a/gtk/gtktoolbar.c b/gtk/gtktoolbar.c index 16f7d3dc87..e117829bc2 100644 --- a/gtk/gtktoolbar.c +++ b/gtk/gtktoolbar.c @@ -3898,7 +3898,7 @@ toolbar_content_new_tool_item (GtkToolbar *toolbar, ToolbarContent *content; GtkToolbarPrivate *priv = GTK_TOOLBAR_GET_PRIVATE (toolbar); - content = g_new0 (ToolbarContent, 1); + content = g_slice_new0 (ToolbarContent); content->type = TOOL_ITEM; content->state = NOT_ALLOCATED; @@ -3934,7 +3934,7 @@ toolbar_content_new_compatibility (GtkToolbar *toolbar, GtkToolbarChild *child; GtkToolbarPrivate *priv = GTK_TOOLBAR_GET_PRIVATE (toolbar); - content = g_new0 (ToolbarContent, 1); + content = g_slice_new0 (ToolbarContent); child = &(content->u.compatibility.child); @@ -4012,7 +4012,7 @@ toolbar_content_remove (ToolbarContent *content, static void toolbar_content_free (ToolbarContent *content) { - g_free (content); + g_slice_free (ToolbarContent, content); } static gint