1
0
mirror of https://github.com/irssi/irssi.git synced 2024-06-30 06:45:25 +00:00

Merge pull request #1077 from l2dy/memory-leak

Fix memory leaks
This commit is contained in:
ailin-nemui 2019-07-28 01:26:57 +02:00 committed by GitHub
commit f612f2ee51
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 1 deletions

View File

@ -229,6 +229,7 @@ static void settings_add(const char *module, const char *section,
if (rec->type != type) {
g_warning("Trying to add already existing "
"setting '%s' with different type.", key);
g_strfreev(choices_vec);
return;
}
rec->refcount++;

View File

@ -92,8 +92,10 @@ static int dcc_ctcp_resume_parse(int type, const char *data, const char *nick,
params = g_strsplit(data, " ", -1);
paramcount = g_strv_length(params);
if (paramcount < 3)
if (paramcount < 3) {
g_strfreev(params);
return 0;
}
fileparams = get_file_params_count_resume(params, paramcount);