mirror of
https://github.com/irssi/irssi.git
synced 2024-12-04 14:46:39 -05:00
If channel has more nicks than /SET channel_max_who_sync, don't ask /WHO
list to avoid getting kicked out of server (Max SendQ exceeded). git-svn-id: http://svn.irssi.org/repos/irssi/trunk@3229 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
parent
ca20209ce2
commit
cc5e5b9f88
@ -364,7 +364,9 @@ static void sig_channel_joined(IRC_CHANNEL_REC *channel)
|
|||||||
/* Add channel to query lists */
|
/* Add channel to query lists */
|
||||||
if (!channel->no_modes)
|
if (!channel->no_modes)
|
||||||
query_add_channel(channel, CHANNEL_QUERY_MODE);
|
query_add_channel(channel, CHANNEL_QUERY_MODE);
|
||||||
query_add_channel(channel, CHANNEL_QUERY_WHO);
|
if (g_hash_table_size(channel->nicks) <
|
||||||
|
settings_get_int("channel_max_who_sync"))
|
||||||
|
query_add_channel(channel, CHANNEL_QUERY_WHO);
|
||||||
if (!channel->no_modes)
|
if (!channel->no_modes)
|
||||||
query_add_channel(channel, CHANNEL_QUERY_BMODE);
|
query_add_channel(channel, CHANNEL_QUERY_BMODE);
|
||||||
|
|
||||||
@ -481,6 +483,7 @@ static void event_end_of_banlist(IRC_SERVER_REC *server, const char *data)
|
|||||||
void channels_query_init(void)
|
void channels_query_init(void)
|
||||||
{
|
{
|
||||||
settings_add_bool("misc", "channel_sync", TRUE);
|
settings_add_bool("misc", "channel_sync", TRUE);
|
||||||
|
settings_add_int("misc", "channel_max_who_sync", 1000);
|
||||||
|
|
||||||
signal_add("server connected", (SIGNAL_FUNC) sig_connected);
|
signal_add("server connected", (SIGNAL_FUNC) sig_connected);
|
||||||
signal_add("server disconnected", (SIGNAL_FUNC) sig_disconnected);
|
signal_add("server disconnected", (SIGNAL_FUNC) sig_disconnected);
|
||||||
|
Loading…
Reference in New Issue
Block a user