1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-27 05:16:38 +02:00

irc: check if arguments are not NULL in some infos

Affected infos:

- irc_server_isupport
- irc_server_isupport_value
- irc_server_cap
- irc_server_cap_value
This commit is contained in:
Sébastien Helleu
2024-01-12 17:53:36 +01:00
parent da256bbad7
commit 62fced3213
2 changed files with 13 additions and 0 deletions
+1
View File
@@ -17,6 +17,7 @@ Bug fixes::
* core: fix crash on plugin reload when using musl libc (issue #2052)
* core: fix infinite loop in display when the chat area is too small (issue #2053)
* irc: check if arguments are not NULL in some infos
* irc: fix info "irc_is_message_ignored" (issue #2059)
* irc: fix display of self messages when the message split fails due to inconsistent max lengths sent by the server in message 005
+12
View File
@@ -343,6 +343,9 @@ irc_info_info_irc_server_isupport_cb (const void *pointer, void *data,
(void) data;
(void) info_name;
if (!arguments || !arguments[0])
return NULL;
isupport_value = NULL;
pos_comma = strchr (arguments, ',');
if (pos_comma)
@@ -381,6 +384,9 @@ irc_info_info_irc_server_isupport_value_cb (const void *pointer, void *data,
(void) data;
(void) info_name;
if (!arguments || !arguments[0])
return NULL;
isupport_value = NULL;
pos_comma = strchr (arguments, ',');
if (pos_comma)
@@ -419,6 +425,9 @@ irc_info_info_irc_server_cap_cb (const void *pointer, void *data,
(void) data;
(void) info_name;
if (!arguments || !arguments[0])
return NULL;
has_cap = 0;
pos_comma = strchr (arguments, ',');
if (pos_comma)
@@ -457,6 +466,9 @@ irc_info_info_irc_server_cap_value_cb (const void *pointer, void *data,
(void) data;
(void) info_name;
if (!arguments || !arguments[0])
return NULL;
cap_value = NULL;
pos_comma = strchr (arguments, ',');
if (pos_comma)