Skip to content

Commit bd0d998

Browse files
sc0wlukefromdc
authored andcommitted
caja-desktop-link-monitor: Fix memory leak
'g_strconcat' needs to be freed
1 parent 78607a5 commit bd0d998

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

‎libcaja-private/caja-desktop-link-monitor.c‎

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -339,11 +339,11 @@ desktop_volumes_visible_changed (gpointer callback_data)
339339
static void
340340
create_link_and_add_preference (CajaDesktopLink **link_ref,
341341
CajaDesktopLinkType link_type,
342-
const char *preference_key,
343-
GCallback callback,
344-
gpointer callback_data)
342+
const char *preference_key,
343+
GCallback callback,
344+
gpointer callback_data)
345345
{
346-
char *detailed_signal;
346+
gchar *detailed_signal;
347347

348348
if (g_settings_get_boolean (caja_desktop_preferences, preference_key))
349349
{
@@ -354,6 +354,7 @@ create_link_and_add_preference (CajaDesktopLink **link_ref,
354354
g_signal_connect_swapped (caja_desktop_preferences,
355355
detailed_signal,
356356
callback, callback_data);
357+
g_free (detailed_signal);
357358
}
358359

359360
static void

0 commit comments

Comments
 (0)