changeset 28409:1d2425f2e4ff

Woah, this was wrong. MY BAD! We should not be setting this to true just because we get an unknown html tag (or in this case an unescaped '<'). This fixes bug #10021 and I think probably another duplicate bug
author Mark Doliner <mark@kingant.net>
date Sat, 22 Aug 2009 18:24:19 +0000
parents bf093003785b
children 7115d04c525a
files libpurple/protocols/yahoo/util.c libpurple/tests/test_yahoo_util.c
diffstat 2 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/libpurple/protocols/yahoo/util.c	Sat Aug 22 07:02:21 2009 +0000
+++ b/libpurple/protocols/yahoo/util.c	Sat Aug 22 18:24:19 2009 +0000
@@ -611,7 +611,6 @@
 				if (match == NULL) {
 					/* Unknown tag.  The user probably typed a less-than sign */
 					g_string_append_c(cdata, x[i]);
-					no_more_gt_brackets = TRUE;
 					g_free(tag);
 					g_free(tag_name);
 					break;
--- a/libpurple/tests/test_yahoo_util.c	Sat Aug 22 07:02:21 2009 +0000
+++ b/libpurple/tests/test_yahoo_util.c	Sat Aug 22 18:24:19 2009 +0000
@@ -100,6 +100,8 @@
 			yahoo_codes_to_html("<font face='Georgia' size='32'>test"));
 	assert_string_equal_free("<font color='#FF0080'><font size='4' absz='15'>test</font></font>",
 			yahoo_codes_to_html("\x1B[35m<font size='15'>test"));
+	assert_string_equal_free(":&lt;",
+			yahoo_codes_to_html("<FADE #ff0000,#00ff00,#0000ff>:<</FADE>"));
 #endif /* !USE_CSS_FORMATTING */
 }
 END_TEST