Mercurial > pidgin.yaz
comparison src/protocols/irc/msgs.c @ 13646:e8e5931e7e8d
[gaim-migrate @ 16047]
fix IRC topics
committer: Tailor Script <tailor@pidgin.im>
author | Daniel Atallah <daniel.atallah@gmail.com> |
---|---|
date | Mon, 17 Apr 2006 14:01:11 +0000 |
parents | 83ec59aefbe5 |
children | 915f26ce1d07 |
comparison
equal
deleted
inserted
replaced
13645:073bc6da6403 | 13646:e8e5931e7e8d |
---|---|
295 void irc_msg_topic(struct irc_conn *irc, const char *name, const char *from, char **args) | 295 void irc_msg_topic(struct irc_conn *irc, const char *name, const char *from, char **args) |
296 { | 296 { |
297 char *chan, *topic, *msg, *nick, *tmp, *tmp2; | 297 char *chan, *topic, *msg, *nick, *tmp, *tmp2; |
298 GaimConversation *convo; | 298 GaimConversation *convo; |
299 | 299 |
300 convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, chan, irc->account); | |
301 if (!convo) { | |
302 gaim_debug(GAIM_DEBUG_ERROR, "irc", "Got a topic for %s, which doesn't exist\n", chan); | |
303 return; | |
304 } | |
305 | |
306 if (!strcmp(name, "topic")) { | 300 if (!strcmp(name, "topic")) { |
307 chan = args[0]; | 301 chan = args[0]; |
308 topic = irc_mirc2txt (args[1]); | 302 topic = irc_mirc2txt (args[1]); |
309 } else { | 303 } else { |
310 chan = args[1]; | 304 chan = args[1]; |
311 topic = irc_mirc2txt (args[2]); | 305 topic = irc_mirc2txt (args[2]); |
306 } | |
307 | |
308 convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, chan, irc->account); | |
309 if (!convo) { | |
310 gaim_debug(GAIM_DEBUG_ERROR, "irc", "Got a topic for %s, which doesn't exist\n", chan); | |
311 g_free(topic); | |
312 return; | |
312 } | 313 } |
313 | 314 |
314 /* If this is an interactive update, print it out */ | 315 /* If this is an interactive update, print it out */ |
315 tmp = g_markup_escape_text(topic, -1); | 316 tmp = g_markup_escape_text(topic, -1); |
316 tmp2 = gaim_markup_linkify(tmp); | 317 tmp2 = gaim_markup_linkify(tmp); |