summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog1
-rw-r--r--src/plugins/irc/irc-command.c4
2 files changed, 3 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index cf164f363..d4ed67c02 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -27,6 +27,7 @@ Version 0.3.6 (under dev!)
hdata_get_string
* api: fix bug with function config_set_desc_plugin (use immediately
description for option when function is called)
+* irc: fix crash when /join command is executed on a non-irc buffer (bug #33742)
* irc: fix bug with comma in irc color code: do not strip comma if it is not
followed by a digit (bug #33662)
* irc: add prefix "#" for all channels on join (if no prefix given)
diff --git a/src/plugins/irc/irc-command.c b/src/plugins/irc/irc-command.c
index b9216d9ce..50f95fed1 100644
--- a/src/plugins/irc/irc-command.c
+++ b/src/plugins/irc/irc-command.c
@@ -1868,13 +1868,13 @@ irc_command_join (void *data, struct t_gui_buffer *buffer, int argc,
}
else
{
- if (!ptr_server)
- return WEECHAT_RC_ERROR;
+ IRC_COMMAND_CHECK_SERVER("join", 1);
irc_command_join_server (ptr_server, argv_eol[1], 1);
}
}
else
{
+ IRC_COMMAND_CHECK_SERVER("join", 1);
if (ptr_channel && (ptr_channel->type == IRC_CHANNEL_TYPE_CHANNEL)
&& !ptr_channel->nicks)
{