aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog7
-rw-r--r--src/bookmarks/ephy-topics-selector.c18
2 files changed, 14 insertions, 11 deletions
diff --git a/ChangeLog b/ChangeLog
index 8ddf3f4fb..a139c4fae 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
2003-08-08 Christian Persch <chp@cvs.gnome.org>
+ * src/bookmarks/ephy-topics-selector: (topic_toggled), (topic_clicked),
+ (topic_key_pressed):
+
+ Fix mem leak.
+
+2003-08-08 Christian Persch <chp@cvs.gnome.org>
+
* lib/widgets/ephy-node-view.c: (cell_renderer_edited):
Fix mem leak.
diff --git a/src/bookmarks/ephy-topics-selector.c b/src/bookmarks/ephy-topics-selector.c
index 9a2a72df5..9d8447731 100644
--- a/src/bookmarks/ephy-topics-selector.c
+++ b/src/bookmarks/ephy-topics-selector.c
@@ -239,12 +239,10 @@ fill_model (EphyTopicsSelector *editor)
}
static void
-topic_toggled (GtkCellRendererToggle *cell,
- char *path_str,
+topic_toggled (GtkTreePath *path,
EphyTopicsSelector *selector)
{
GtkTreeModel *model = selector->priv->model;
- GtkTreePath *path = gtk_tree_path_new_from_string (path_str);
GtkTreeIter iter;
gboolean has_topic;
@@ -318,9 +316,8 @@ topic_clicked (GtkTreeView *tree_view,
&path, NULL,
NULL, NULL))
{
- gchar *path_str = gtk_tree_path_to_string (path);
- topic_toggled (NULL, path_str, selector);
- g_free(path_str);
+ topic_toggled (path, selector);
+
gtk_tree_path_free (path);
}
@@ -334,8 +331,7 @@ topic_key_pressed (GtkTreeView *tree_view,
{
GtkTreeSelection *sel = NULL;
GtkTreeIter iter;
- GtkTreePath *path = NULL;
- gchar *path_str;
+ GtkTreePath *path;
switch (event->keyval)
{
@@ -347,9 +343,9 @@ topic_key_pressed (GtkTreeView *tree_view,
if (gtk_tree_selection_get_selected (sel, NULL, &iter))
{
path = gtk_tree_model_get_path (selector->priv->model, &iter);
- path_str = gtk_tree_path_to_string (path);
- topic_toggled (NULL, path_str, selector);
- g_free(path_str);
+
+ topic_toggled (path, selector);
+
gtk_tree_path_free (path);
}
return TRUE;