mirror of
https://github.com/weechat/weechat.git
synced 2026-06-12 14:14:48 +02:00
core: fix memory leak when infolist variable can not be created
This commit is contained in:
@@ -1082,7 +1082,11 @@ hook_command_add_to_infolist (struct t_infolist_item *item,
|
||||
HOOK_COMMAND(hook, args_description));
|
||||
if (!infolist_new_var_string (item, "args_description_nls",
|
||||
(args_desc_nls) ? args_desc_nls : ""))
|
||||
{
|
||||
if (args_desc_nls)
|
||||
free (args_desc_nls);
|
||||
return 0;
|
||||
}
|
||||
if (args_desc_nls)
|
||||
free (args_desc_nls);
|
||||
if (!infolist_new_var_string (item, "completion", HOOK_COMMAND(hook, completion)))
|
||||
|
||||
Reference in New Issue
Block a user