Commit 0c4b5067 authored by Young-Ho Cha's avatar Young-Ho Cha Committed by Tim-Philipp Müller
Browse files

gst/subparse/samiparse.c: More case-insensitivity for certain tags; recognise...

gst/subparse/samiparse.c: More case-insensitivity for certain tags; recognise entities with decimal codes as special ...

Original commit message from CVS:
Patch by: Young-Ho Cha <ganadist at chollian dot net>
* gst/subparse/samiparse.c: (handle_start_font),
(fix_invalid_entities):
More case-insensitivity for certain tags; recognise entities with
decimal codes as special entities as well (#357330).
parent 77c1be94
2006-09-23 Tim-Philipp Müller <tim at centricular dot net>
Patch by: Young-Ho Cha <ganadist at chollian dot net>
* gst/subparse/samiparse.c: (handle_start_font),
(fix_invalid_entities):
More case-insensitivity for certain tags; recognise entities with
decimal codes as special entities as well (#357330).
2006-09-23 Tim-Philipp Müller <tim at centricular dot net>
 
* gst-libs/gst/Makefile.am:
......@@ -177,12 +177,12 @@ handle_start_font (GstSamiContext * sctx, const xmlChar ** atts)
}
/* silver colour can be found in many sami files, but X RGB database
* doesn't contain a colour by this name, so map explicitly */
if (!xmlStrncmp ((const xmlChar *) "silver", value, 6)) {
if (!xmlStrncasecmp ((const xmlChar *) "silver", value, 6)) {
value = (const xmlChar *) "#c0c0c0";
}
g_string_append_printf (sctx->buf, " foreground=\"%s%s\"", sharp,
value);
} else if (!xmlStrncmp ((const xmlChar *) "face", key, 4)) {
} else if (!xmlStrncasecmp ((const xmlChar *) "face", key, 4)) {
g_string_append_printf (sctx->buf, " font_family=\"%s\"", value);
}
}
......@@ -376,7 +376,8 @@ fix_invalid_entities (const gchar * line)
&& g_ascii_strncasecmp (cp, "apos;", 5)
&& g_ascii_strncasecmp (cp, "lt;", 3)
&& g_ascii_strncasecmp (cp, "gt;", 3)
&& g_ascii_strncasecmp (cp, "nbsp;", 5)) {
&& g_ascii_strncasecmp (cp, "nbsp;", 5)
&& cp[0] != '#') {
/* translate "&" to "&amp;" */
ret = g_string_append_len (ret, "&amp;", 5);
} else {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment