introduce auto_gcharv

This also fixes memory leaks in `_omemo_autocomplete()`.

Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
This commit is contained in:
Steffen Jaeckel
2023-01-18 16:43:53 +01:00
parent b535921484
commit 99ffaf0a00
3 changed files with 23 additions and 71 deletions

View File

@@ -78,6 +78,14 @@ auto_free_gchar(gchar** str)
g_free(*str);
}
void
auto_free_gcharv(gchar*** args)
{
if (args == NULL)
return;
g_strfreev(*args);
}
void
auto_free_char(char** str)
{