# HG changeset patch # User Eric Warmenhoven # Date 1001012637 0 # Node ID 14c8df9cc75f0cc9e8f0a0f26480ceefd6c45d9a # Parent f74eefb55a78947a2cbad6cc322b39ae9b613195 [gaim-migrate @ 2338] hi committer: Tailor Script diff -r f74eefb55a78 -r 14c8df9cc75f src/protocols/irc/irc.c --- a/src/protocols/irc/irc.c Thu Sep 20 18:36:15 2001 +0000 +++ b/src/protocols/irc/irc.c Thu Sep 20 19:03:57 2001 +0000 @@ -416,8 +416,13 @@ *po = 0; po += 2; - if ((c = irc_find_chat(gc, text))) + if ((c = irc_find_chat(gc, text))) { + char buf[IRC_BUF_LEN]; chat_set_topic(c, NULL, po); + g_snprintf(buf, sizeof(buf), _("%s has changed the topic to: %s"), + text, po); + write_to_conv(c, buf, WFLAG_SYSTEM, NULL, time(NULL)); + } } static gboolean mode_has_arg(struct gaim_connection *gc, char sign, char mode) @@ -847,8 +852,13 @@ } else if (!strcmp(cmd, "TOPIC")) { struct conversation *c = irc_find_chat(gc, word[3]); char *topic = *word_eol[4] == ':' ? word_eol[4] + 1 : word_eol[4]; - if (c) + if (c) { + char buf[IRC_BUF_LEN]; chat_set_topic(c, nick, topic); + g_snprintf(buf, sizeof(buf), _("%s has changed the topic to: %s"), + nick, topic); + write_to_conv(c, buf, WFLAG_SYSTEM, NULL, time(NULL)); + } } else if (!strcmp(cmd, "WALLOPS")) { /* */ } }