summaryrefslogtreecommitdiff
path: root/libcaja-private
diff options
context:
space:
mode:
authorPablo Barciela <[email protected]>2018-12-01 20:49:52 +0100
committerlukefromdc <[email protected]>2018-12-01 20:12:41 +0000
commitc12b61baf724eb1df58064b19f907c4b51fa762f (patch)
tree08ecacfa6d56e26305cd4a114b485a62a61e3fab /libcaja-private
parenta8de3bb404dfd502b4367bbcfa63fff3dfa199b8 (diff)
downloadcaja-c12b61baf724eb1df58064b19f907c4b51fa762f.tar.bz2
caja-c12b61baf724eb1df58064b19f907c4b51fa762f.tar.xz
caja-bookmark: Fix memory leak
'g_strconcat' needs to be freed
Diffstat (limited to 'libcaja-private')
-rw-r--r--libcaja-private/caja-bookmark.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/libcaja-private/caja-bookmark.c b/libcaja-private/caja-bookmark.c
index 76fba803..af7a899e 100644
--- a/libcaja-private/caja-bookmark.c
+++ b/libcaja-private/caja-bookmark.c
@@ -605,6 +605,7 @@ bookmark_image_menu_item_new_from_surface (cairo_surface_t *icon_surface,
{
GtkWidget *icon;
GtkLabel *label;
+ gchar *concat;
GtkWidget *box = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6);
@@ -613,7 +614,9 @@ bookmark_image_menu_item_new_from_surface (cairo_surface_t *icon_surface,
else
icon = gtk_image_new ();
- GtkWidget *label_menu = gtk_label_new (g_strconcat (label_name, " ", NULL));
+ concat = g_strconcat (label_name, " ", NULL);
+ GtkWidget *label_menu = gtk_label_new (concat);
+ g_free (concat);
label = GTK_LABEL (label_menu);
gtk_label_set_use_underline (label, FALSE);