summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormonsta <[email protected]>2014-11-02 11:36:43 +0300
committerinfirit <[email protected]>2014-11-28 09:06:14 +0100
commiteb0515688e368e97fdf93b1083b233f0ae732948 (patch)
tree99052138cb3b61795c922a43c555973708af905a
parent5456636eee15246e2e061633c8601daf1bc04b07 (diff)
downloadmate-settings-daemon-eb0515688e368e97fdf93b1083b233f0ae732948.tar.bz2
mate-settings-daemon-eb0515688e368e97fdf93b1083b233f0ae732948.tar.xz
don't leak memory
-rw-r--r--plugins/xsettings/msd-xsettings-manager.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/plugins/xsettings/msd-xsettings-manager.c b/plugins/xsettings/msd-xsettings-manager.c
index 8c1b9fb..9c91e82 100644
--- a/plugins/xsettings/msd-xsettings-manager.c
+++ b/plugins/xsettings/msd-xsettings-manager.c
@@ -407,7 +407,7 @@ update_property (GString *props, const gchar* key, const gchar* value)
if (g_str_has_prefix (props->str, needle))
found = props->str;
else
- found = strstr (props->str, needle);
+ found = strstr (props->str, needle);
if (found) {
size_t value_index;
@@ -421,6 +421,8 @@ update_property (GString *props, const gchar* key, const gchar* value)
} else {
g_string_append_printf (props, "%s:\t%s\n", key, value);
}
+
+ g_free (needle);
}
static void