From 045ceb961fd8af1f0c7e65914e55125956df8317 Mon Sep 17 00:00:00 2001 From: Sebastien Helleu Date: Thu, 9 Nov 2006 22:33:44 +0000 Subject: [PATCH] Fixed bug in charset plugin: now encode/decode channels/nicks in IRC messages (after command) --- src/plugins/charset/weechat-charset.c | 7 +------ weechat/src/plugins/charset/weechat-charset.c | 7 +------ 2 files changed, 2 insertions(+), 12 deletions(-) diff --git a/src/plugins/charset/weechat-charset.c b/src/plugins/charset/weechat-charset.c index c5adaf894..1fd8d4e62 100644 --- a/src/plugins/charset/weechat-charset.c +++ b/src/plugins/charset/weechat-charset.c @@ -256,6 +256,7 @@ weechat_charset_parse_irc_msg (char *message, char **nick, char **command, *pos_args = pos2 + 1; else { + *pos_args = pos2; if ((pos2[0] == '#') || (pos2[0] == '&') || (pos2[0] == '+') || (pos2[0] == '!')) { @@ -276,12 +277,6 @@ weechat_charset_parse_irc_msg (char *message, char **nick, char **command, *nick = strdup (pos2); } } - if (pos3) - { - while (pos3[0] == ' ') - pos3++; - *pos_args = (pos3[0] == ':') ? pos3 + 1 : pos3; - } } } } diff --git a/weechat/src/plugins/charset/weechat-charset.c b/weechat/src/plugins/charset/weechat-charset.c index c5adaf894..1fd8d4e62 100644 --- a/weechat/src/plugins/charset/weechat-charset.c +++ b/weechat/src/plugins/charset/weechat-charset.c @@ -256,6 +256,7 @@ weechat_charset_parse_irc_msg (char *message, char **nick, char **command, *pos_args = pos2 + 1; else { + *pos_args = pos2; if ((pos2[0] == '#') || (pos2[0] == '&') || (pos2[0] == '+') || (pos2[0] == '!')) { @@ -276,12 +277,6 @@ weechat_charset_parse_irc_msg (char *message, char **nick, char **command, *nick = strdup (pos2); } } - if (pos3) - { - while (pos3[0] == ' ') - pos3++; - *pos_args = (pos3[0] == ':') ? pos3 + 1 : pos3; - } } } }