mirror of
https://github.com/irssi/irssi.git
synced 2024-11-03 04:27:19 -05:00
Recode outgoing irc away messages, bug #412.
git-svn-id: file:///var/www/svn.irssi.org/SVN/irssi/trunk@4901 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
parent
cf41f6d45d
commit
27be963a86
@ -348,16 +348,21 @@ static void sig_server_quit(IRC_SERVER_REC *server, const char *msg)
|
|||||||
|
|
||||||
void irc_server_send_away(IRC_SERVER_REC *server, const char *reason)
|
void irc_server_send_away(IRC_SERVER_REC *server, const char *reason)
|
||||||
{
|
{
|
||||||
|
char *recoded = NULL;
|
||||||
|
|
||||||
if (!IS_IRC_SERVER(server))
|
if (!IS_IRC_SERVER(server))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (*reason != '\0' || server->usermode_away) {
|
if (*reason != '\0' || server->usermode_away) {
|
||||||
g_free_and_null(server->away_reason);
|
g_free_and_null(server->away_reason);
|
||||||
if (*reason != '\0')
|
if (*reason != '\0') {
|
||||||
server->away_reason = g_strdup(reason);
|
server->away_reason = g_strdup(reason);
|
||||||
|
reason = recoded = recode_out(SERVER(server), reason, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
irc_send_cmdv(server, "AWAY :%s", reason);
|
irc_send_cmdv(server, "AWAY :%s", reason);
|
||||||
}
|
}
|
||||||
|
g_free(recoded);
|
||||||
}
|
}
|
||||||
|
|
||||||
void irc_server_send_data(IRC_SERVER_REC *server, const char *data, int len)
|
void irc_server_send_data(IRC_SERVER_REC *server, const char *data, int len)
|
||||||
|
Loading…
Reference in New Issue
Block a user