diff options
author | James Booth <boothj5@gmail.com> | 2014-06-15 17:19:56 +0100 |
---|---|---|
committer | James Booth <boothj5@gmail.com> | 2014-06-15 17:19:56 +0100 |
commit | e296379863424d50b300ca95f3b577a7e8a4ac83 (patch) | |
tree | 2fbc15da48c507afbdb12d8dc4cf99563a9e1ed6 /src/config | |
parent | c505f4aaba555eb8e4ce6aceb723ea6934acbcf1 (diff) | |
download | profani-tty-e296379863424d50b300ca95f3b577a7e8a4ac83.tar.gz |
Fixed memleak when writing preferences file
Diffstat (limited to 'src/config')
-rw-r--r-- | src/config/preferences.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/config/preferences.c b/src/config/preferences.c index 32473848..6c41cdfa 100644 --- a/src/config/preferences.c +++ b/src/config/preferences.c @@ -360,8 +360,9 @@ static void _save_prefs(void) { gsize g_data_size; - char *g_prefs_data = g_key_file_to_data(prefs, &g_data_size, NULL); + gchar *g_prefs_data = g_key_file_to_data(prefs, &g_data_size, NULL); g_file_set_contents(prefs_loc, g_prefs_data, g_data_size, NULL); + g_free(g_prefs_data); } static gchar * |