mirror of
https://github.com/weechat/weechat.git
synced 2026-06-27 05:16:38 +02:00
Fixed bug with "set_config" function in plugins API (bug #18448)
This commit is contained in:
@@ -796,9 +796,10 @@ weechat_plugin_set_config (t_weechat_plugin *plugin, char *option, char *value)
|
||||
{
|
||||
/* server config option modification */
|
||||
server_name = (char *)malloc (pos - option + 1);
|
||||
strncpy (server_name, option, pos - option);
|
||||
if (server_name)
|
||||
{
|
||||
strncpy (server_name, option, pos - option);
|
||||
server_name[pos - option] = '\0';
|
||||
ptr_server = server_search (server_name);
|
||||
free (server_name);
|
||||
if (ptr_server)
|
||||
|
||||
Reference in New Issue
Block a user