1 diff -up dbus-glib-0.73/dbus/dbus-gparser.c.ignore-namespaces dbus-glib-0.73/dbus/dbus-gparser.c
2 --- dbus-glib-0.73/dbus/dbus-gparser.c.ignore-namespaces 2006-09-27 08:27:24.000000000 -0400
3 +++ dbus-glib-0.73/dbus/dbus-gparser.c 2008-03-13 08:54:14.000000000 -0400
4 @@ -128,13 +128,17 @@ locate_attributes (const char *element_
10 - G_MARKUP_ERROR_PARSE,
11 - _("Attribute \"%s\" is invalid on <%s> element in this context"),
12 - attribute_names[i], element_name);
15 + /* We want to passthrough namespaced XML nodes that we don't know anything about. */
16 + if (strchr (attribute_names[i], ':') == NULL)
20 + G_MARKUP_ERROR_PARSE,
21 + _("Attribute \"%s\" is invalid on <%s> element in this context"),
22 + attribute_names[i], element_name);
29 @@ -177,6 +181,7 @@ struct Parser
30 PropertyInfo *property;
32 gboolean in_annotation;
33 + guint unknown_namespaced_depth;
37 @@ -791,10 +796,14 @@ parser_start_element (Parser *parse
41 - g_set_error (error, G_MARKUP_ERROR,
42 - G_MARKUP_ERROR_PARSE,
43 - _("Element <%s> not recognized"),
45 + if (strchr (element_name, ':') != NULL)
46 + /* Passthrough XML-namespaced nodes */
47 + parser->unknown_namespaced_depth += 1;
48 + else if (parser->unknown_namespaced_depth == 0)
49 + g_set_error (error, G_MARKUP_ERROR,
50 + G_MARKUP_ERROR_PARSE,
51 + _("Element <%s> not recognized"),
56 @@ -844,6 +853,15 @@ parser_end_element (Parser *parser,
57 if (parser->node_stack == NULL)
58 parser->result = top; /* We are done, store the result */
60 + else if (strchr (element_name, ':') != NULL)
62 + /* Passthrough XML-namespaced nodes */
63 + parser->unknown_namespaced_depth -= 1;
65 + else if (parser->unknown_namespaced_depth > 0)
67 + /* pass through unknown elements underneath a namespace */
70 g_assert_not_reached (); /* should have had an error on start_element */
72 diff -up dbus-glib-0.73/dbus/dbus-glib-tool.c.ignore-namespaces dbus-glib-0.73/dbus/dbus-glib-tool.c
73 --- dbus-glib-0.73/dbus/dbus-glib-tool.c.ignore-namespaces 2008-03-13 08:31:21.000000000 -0400
74 +++ dbus-glib-0.73/dbus/dbus-glib-tool.c 2008-03-13 08:32:15.000000000 -0400
75 @@ -414,7 +414,7 @@ main (int argc, char **argv)
79 - lose_gerror (_("Unable to load \"%s\""), error);
80 + lose (_("Unable to load \"%s\": %s"), filename, error->message);