1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-26 12:56:37 +02:00

plugins: remove check of NULL pointers before calling weechat_string_free_split() (issue #865)

This commit is contained in:
Sébastien Helleu
2024-04-25 19:07:02 +02:00
parent f11c7c1bf4
commit 9a5a1fb300
32 changed files with 65 additions and 135 deletions
+3 -6
View File
@@ -436,8 +436,7 @@ trigger_command_list_default (int verbose)
}
trigger_regex_free (&regex_count, &regex);
if (commands)
weechat_string_free_split (commands);
weechat_string_free_split (commands);
}
/*
@@ -838,8 +837,7 @@ trigger_command_trigger (const void *pointer, void *data,
weechat_buffer_set (buffer, "input_pos", "13");
free (input);
}
if (items)
weechat_string_free_split (items);
weechat_string_free_split (items);
goto end;
}
@@ -1242,8 +1240,7 @@ error:
rc = WEECHAT_RC_ERROR;
end:
if (sargv)
weechat_string_free_split (sargv);
weechat_string_free_split (sargv);
if (rc == WEECHAT_RC_ERROR)
WEECHAT_COMMAND_ERROR;