summaryrefslogtreecommitdiff
path: root/src/plugins/irc/irc-ignore.c
diff options
context:
space:
mode:
authorSébastien Helleu <flashcode@flashtux.org>2023-01-27 20:47:24 +0100
committerSébastien Helleu <flashcode@flashtux.org>2023-01-28 15:14:22 +0100
commitc07cf691adb4740759e9fd128a2f6702c912d70f (patch)
tree91520d9be1270aae41d23ffeae1f69d3a31b10d2 /src/plugins/irc/irc-ignore.c
parentc9ac4fef4b7aa054df72bddf667edea0608d39c6 (diff)
downloadweechat-c07cf691adb4740759e9fd128a2f6702c912d70f.zip
core, plugins: check that string parameters are not NULL in search functions (issue #1872)
Diffstat (limited to 'src/plugins/irc/irc-ignore.c')
-rw-r--r--src/plugins/irc/irc-ignore.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/plugins/irc/irc-ignore.c b/src/plugins/irc/irc-ignore.c
index b39e107b8..02202e995 100644
--- a/src/plugins/irc/irc-ignore.c
+++ b/src/plugins/irc/irc-ignore.c
@@ -73,6 +73,9 @@ irc_ignore_search (const char *mask, const char *server, const char *channel)
struct t_irc_ignore *ptr_ignore;
char any[2] = "*";
+ if (!mask)
+ return NULL;
+
if (!server)
server = any;
if (!channel)