[gnome-commander/get_rid_of_xml] Free the pointer to the pointer array in get_list_from_gsettings_string_array
- From: Uwe Scholz <uwescholz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-commander/get_rid_of_xml] Free the pointer to the pointer array in get_list_from_gsettings_string_array
- Date: Mon, 3 Dec 2018 15:54:42 +0000 (UTC)
commit 481dc965cad959c498982063cac7c5f229ae6795
Author: Uwe Scholz <u scholz83 gmx de>
Date: Fri Nov 23 11:19:05 2018 +0100
Free the pointer to the pointer array in get_list_from_gsettings_string_array
src/gnome-cmd-data.cc | 4 ++++
1 file changed, 4 insertions(+)
---
diff --git a/src/gnome-cmd-data.cc b/src/gnome-cmd-data.cc
index 08b2acae..a9f8f01e 100644
--- a/src/gnome-cmd-data.cc
+++ b/src/gnome-cmd-data.cc
@@ -2635,6 +2635,9 @@ inline GList* GnomeCmdData::load_string_history (const gchar *format, gint size)
#endif
+/**
+ * Returns a GList with newly allocated char strings
+ */
inline GList* GnomeCmdData::get_list_from_gsettings_string_array (GSettings *settings_given, const gchar
*key)
{
GList *list = NULL;
@@ -2646,6 +2649,7 @@ inline GList* GnomeCmdData::get_list_from_gsettings_string_array (GSettings *set
list = g_list_append (list, gsettings_array[i]);
}
+ g_free(gsettings_array);
return list;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]