Fix plugin command memleak

This commit is contained in:
James Booth
2016-02-15 00:09:51 +00:00
parent bd928f0f29
commit 7945ef5277
4 changed files with 11 additions and 2 deletions

View File

@@ -591,7 +591,7 @@ prefs_set_autoxa_time(gint value)
_save_prefs();
}
gchar **
gchar**
prefs_get_plugins(void)
{
if (!g_key_file_has_group(prefs, "plugins")) {
@@ -604,6 +604,12 @@ prefs_get_plugins(void)
return g_key_file_get_string_list(prefs, "plugins", "load", NULL, NULL);
}
void
prefs_free_plugins(gchar **plugins)
{
g_strfreev(plugins);
}
void
prefs_set_occupants_size(gint value)
{

View File

@@ -184,6 +184,7 @@ gint prefs_get_autoxa_time(void);
void prefs_set_autoxa_time(gint value);
gchar** prefs_get_plugins(void);
void prefs_free_plugins(gchar **plugins);
char prefs_get_otr_char(void);
void prefs_set_otr_char(char ch);