Index: src/gtkimhtml.c
===================================================================
RCS file: /cvsroot/gaim/gaim/src/gtkimhtml.c,v
retrieving revision 1.363
diff -u -p -r1.363 gtkimhtml.c
--- src/gtkimhtml.c 22 Aug 2004 03:58:59 -0000 1.363
+++ src/gtkimhtml.c 31 Aug 2004 16:39:54 -0000
@@ -1739,20 +1739,11 @@ gtk_imhtml_is_tag (const gchar *string,
if (!g_ascii_strncasecmp(string, "!--", strlen ("!--"))) {
gchar *e = strstr (string + strlen("!--"), "-->");
if (e) {
- /*
- * If we uncomment the following line then HTML comments will be
- * hidden. This is good because it means when a WinAIM users pastes
- * part of a conversation to you, the screen names won't be
- * duplicated (because WinAIM pastes an HTML comment containing the
- * screen name, for some reason).
- *
- * However, uncommenting this is bad because we use HTML comment
- * tags to print timestamps to conversations (at least, I think...)
- *
- * KingAnt thinks it would be best to display timestamps using
- * something other than comment tags.
- */
- /* *type = -1; */
+ /* Ugly hack so that timestamp HTML comments are not treated as comments but
+ * other comments are. Yuck. */
+ if (g_ascii_strncasecmp(string, "!--(", strlen ("!--(")) &&
+ g_ascii_strncasecmp(e - strlen(") "), ") -->", strlen(") -->")))
+ *type = -1;
*len = e - string + strlen ("-->");
*tag = g_strndup (string + strlen ("!--"), *len - strlen ("!---->"));
return TRUE;