summaryrefslogtreecommitdiff
path: root/src/plugins/irc/irc-command.c
diff options
context:
space:
mode:
authorSebastien Helleu <flashcode@flashtux.org>2008-12-19 17:43:37 +0100
committerSebastien Helleu <flashcode@flashtux.org>2008-12-19 17:43:37 +0100
commit13e3f3c7f04a805568ebb9a044d81d1eb32aedd6 (patch)
tree2cd321253a56b5a7f3ee7bca61a5cb90f3692a97 /src/plugins/irc/irc-command.c
parentb97db3c31e10e75815d78d5a510953c63fcc2dbf (diff)
downloadweechat-13e3f3c7f04a805568ebb9a044d81d1eb32aedd6.zip
Fix charset problem with IRC plugin: use server charset if channel charset is not set
Diffstat (limited to 'src/plugins/irc/irc-command.c')
-rw-r--r--src/plugins/irc/irc-command.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/plugins/irc/irc-command.c b/src/plugins/irc/irc-command.c
index c064b3770..f6cf3abeb 100644
--- a/src/plugins/irc/irc-command.c
+++ b/src/plugins/irc/irc-command.c
@@ -2779,7 +2779,7 @@ irc_command_server (void *data, struct t_gui_buffer *buffer, int argc,
int i, detailed_list, one_server_found, length;
int default_autoconnect, default_ipv6, default_ssl;
struct t_irc_server server_tmp, *ptr_server2, *server_found, *new_server;
- char *server_name, *mask, value[16];
+ char *server_name, *mask, value[16], charset_modifier[256];
struct t_infolist *infolist;
struct t_config_option *ptr_option;
@@ -3179,6 +3179,11 @@ irc_command_server (void *data, struct t_gui_buffer *buffer, int argc,
}
}
irc_server_set_buffer_title (irc_current_server);
+ snprintf (charset_modifier, sizeof (charset_modifier),
+ "irc.%s", irc_current_server->name);
+ weechat_buffer_set (irc_current_server->buffer,
+ "localvar_set_charset_modifier",
+ charset_modifier);
weechat_bar_item_update ("buffer_name");
weechat_bar_item_update ("input_prompt");
}