mirror of
https://github.com/profanity-im/profanity.git
synced 2024-11-03 19:37:16 -05:00
Free tokens when 0 supplied an 0 min, parse_args_with_freetext
This commit is contained in:
parent
acc4a00d78
commit
ecedca8a95
@ -278,6 +278,7 @@ parse_args_with_freetext(const char * const inp, int min, int max, gboolean *res
|
||||
|
||||
// if min allowed is 0 and 0 found, return empty char* array
|
||||
} else if (min == 0 && num == 0) {
|
||||
g_slist_free_full(tokens, free);
|
||||
gchar **args = malloc((num + 1) * sizeof(*args));
|
||||
args[0] = NULL;
|
||||
*result = TRUE;
|
||||
|
Loading…
Reference in New Issue
Block a user