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

irc: use key when /join-ing in open channel buffer

This commit is contained in:
Simmo Saan
2018-09-09 20:37:30 +03:00
committed by Sébastien Helleu
parent de3ee174e4
commit 6edc88f7d6
4 changed files with 9 additions and 8 deletions
+4 -3
View File
@@ -1417,7 +1417,8 @@ irc_channel_join_smart_filtered_unmask (struct t_irc_channel *channel,
*/
void
irc_channel_rejoin (struct t_irc_server *server, struct t_irc_channel *channel)
irc_channel_rejoin (struct t_irc_server *server, struct t_irc_channel *channel,
int manual_join, int noswitch)
{
char join_args[1024];
@@ -1426,7 +1427,7 @@ irc_channel_rejoin (struct t_irc_server *server, struct t_irc_channel *channel)
(channel->key) ? " " : "",
(channel->key) ? channel->key : "");
irc_command_join_server (server, join_args, 0, 1);
irc_command_join_server (server, join_args, manual_join, noswitch);
}
/*
@@ -1463,7 +1464,7 @@ irc_channel_autorejoin_cb (const void *pointer, void *data,
if (ptr_server_found && (ptr_channel_arg->hook_autorejoin))
{
irc_channel_rejoin (ptr_server_found, ptr_channel_arg);
irc_channel_rejoin (ptr_server_found, ptr_channel_arg, 0, 1);
ptr_channel_arg->hook_autorejoin = NULL;
}
+3 -2
View File
@@ -174,8 +174,9 @@ extern void irc_channel_join_smart_filtered_remove (struct t_irc_channel *channe
const char *nick);
extern void irc_channel_join_smart_filtered_unmask (struct t_irc_channel *channel,
const char *nick);
extern void irc_channel_rejoin (struct t_irc_server *server,
struct t_irc_channel *channel);
extern void
irc_channel_rejoin (struct t_irc_server *server, struct t_irc_channel *channel,
int manual_join, int noswitch);
extern int irc_channel_autorejoin_cb (const void *pointer, void *data,
int remaining_calls);
extern void irc_channel_display_nick_back_in_pv (struct t_irc_server *server,
+1 -2
View File
@@ -3040,8 +3040,7 @@ IRC_COMMAND_CALLBACK(join)
if (ptr_channel && (ptr_channel->type == IRC_CHANNEL_TYPE_CHANNEL)
&& !ptr_channel->nicks)
{
irc_command_join_server (ptr_server, ptr_channel->name,
1, noswitch);
irc_channel_rejoin (ptr_server, ptr_channel, 1, noswitch);
}
else
{
+1 -1
View File
@@ -1952,7 +1952,7 @@ IRC_PROTOCOL_CALLBACK(kick)
IRC_SERVER_OPTION_AUTOREJOIN_DELAY) == 0)
{
/* immediately rejoin if delay is 0 */
irc_channel_rejoin (server, ptr_channel);
irc_channel_rejoin (server, ptr_channel, 0, 1);
}
else
{