mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Memory leak in gnc-gsettings.c
This commit is contained in:
parent
97b7c26570
commit
cb88fe8f93
@ -95,7 +95,7 @@ static GSettings * gnc_gsettings_get_schema_ptr (const gchar *schema_str)
|
|||||||
|
|
||||||
ENTER("");
|
ENTER("");
|
||||||
if (!schema_hash)
|
if (!schema_hash)
|
||||||
schema_hash = g_hash_table_new (g_str_hash, g_str_equal);
|
schema_hash = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, NULL);
|
||||||
|
|
||||||
gset = g_hash_table_lookup (schema_hash, full_name);
|
gset = g_hash_table_lookup (schema_hash, full_name);
|
||||||
DEBUG ("Looking for schema %s returned gsettings %p", full_name, gset);
|
DEBUG ("Looking for schema %s returned gsettings %p", full_name, gset);
|
||||||
@ -108,8 +108,10 @@ static GSettings * gnc_gsettings_get_schema_ptr (const gchar *schema_str)
|
|||||||
else
|
else
|
||||||
PWARN ("Ignoring attempt to access unknown gsettings schema %s", full_name);
|
PWARN ("Ignoring attempt to access unknown gsettings schema %s", full_name);
|
||||||
}
|
}
|
||||||
|
else
|
||||||
g_free(full_name);
|
{
|
||||||
|
g_free(full_name);
|
||||||
|
}
|
||||||
|
|
||||||
LEAVE("");
|
LEAVE("");
|
||||||
return gset;
|
return gset;
|
||||||
|
Loading…
Reference in New Issue
Block a user