From: Nathan W. <fac...@us...> - 2004-06-12 21:48:57
|
Update of /cvsroot/gaim/gaim/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv27392/src Modified Files: util.c Log Message: this fixes a logging issue with apostrophes Index: util.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/util.c,v retrieving revision 1.304 retrieving revision 1.305 diff -u -d -p -r1.304 -r1.305 --- util.c 10 Jun 2004 06:43:26 -0000 1.304 +++ util.c 12 Jun 2004 21:48:49 -0000 1.305 @@ -1332,6 +1332,9 @@ gaim_markup_strip_html(const char *str) visible = TRUE; } + /* XXX: This sucks. We need to be un-escaping all entities, which + * includes these, as well as the &#num; ones */ + if (str2[i] == '&' && strncasecmp(str2 + i, """, 6) == 0) { str2[j++] = '\"'; @@ -1360,6 +1363,13 @@ gaim_markup_strip_html(const char *str) continue; } + if (str2[i] == '&' && strncasecmp(str2 + i, "'", 6) == 0) + { + str2[j++] = '\''; + i = i + 5; + continue; + } + if (visible) str2[j++] = g_ascii_isspace(str2[i])? ' ': str2[i]; } |