inpcom.c: plug memory leaks

This commit is contained in:
h_vogt 2013-09-08 13:01:26 +02:00 committed by rlar
parent 4d7c993c6e
commit 3018a64697
1 changed files with 2 additions and 1 deletions

View File

@ -3131,6 +3131,7 @@ inp_expand_macro_in_str(struct function_env *env, char *str)
sprintf(curr_str + curr_str_len, "%s(%s)", str, macro_str);
}
*fcn_name = keep;
tfree(macro_str);
search_ptr = str = close_paren_ptr + 1;
}
@ -3870,7 +3871,7 @@ inp_sort_params(struct line *start_card, struct line *end_card, struct line *car
ptr_array_ordered[i]->li_next = ptr_array_ordered[i+1];
// clean up memory
for (i = 0; i < num_params; i++) {
for (i = 0; i < arr_size; i++) {
tfree(param_names[i]);
tfree(param_strs[i]);
}