[gaim-migrate @ 15254]

Tue, 17 Jan 2006 01:44:31 +0000

author
Sadrul Habib Chowdhury <sadrul@pidgin.im>
date
Tue, 17 Jan 2006 01:44:31 +0000
changeset 12901
85ddd02a44d1
parent 12900
7fe519669e07
child 12902
de9e0cc3feab

[gaim-migrate @ 15254]
SF Patch #1406029 from Sadrul

"This is a fix for bug #1404394. The fix is to always
linkify the text that will be displayed, and linkify
the text being sent only when the conversation has the
appropriate flags set."

committer: Richard Laager <rlaager@pidgin.im>

src/conversation.c file | annotate | diff | comparison | revisions
--- a/src/conversation.c	Tue Jan 17 01:43:33 2006 +0000
+++ b/src/conversation.c	Tue Jan 17 01:44:31 2006 +0000
@@ -107,13 +107,16 @@
 	type = gaim_conversation_get_type(conv);
 	ops  = gaim_conversation_get_ui_ops(conv);
 
+	/* Always linkfy the text for display */
+	displayed = gaim_markup_linkify(message);
+
 	if ((conv->features & GAIM_CONNECTION_HTML) &&
 		!(msgflags & GAIM_MESSAGE_RAW))
 	{
-		displayed = gaim_markup_linkify(message);
+		sent = g_strdup(displayed);
 	}
 	else
-		displayed = g_strdup(message);
+		sent = g_strdup(message);
 
 	plugin_return =
 		GPOINTER_TO_INT(gaim_signal_emit_return_1(
@@ -133,8 +136,6 @@
 		(type == GAIM_CONV_TYPE_IM ? "wrote-im-msg" : "wrote-chat-msg"),
 		account, conv, displayed);
 
-	sent = g_strdup(displayed);
-
 	msgflags |= GAIM_MESSAGE_SEND;
 
 	if (type == GAIM_CONV_TYPE_IM) {

mercurial