Commit 6da1f01d authored by Rico Tzschichholz's avatar Rico Tzschichholz

g-i: Fix return value on error in start_discriminator()

parent a0d437af
...@@ -1562,9 +1562,16 @@ start_discriminator (GMarkupParseContext *context, ...@@ -1562,9 +1562,16 @@ start_discriminator (GMarkupParseContext *context,
type = find_attribute ("type", attribute_names, attribute_values); type = find_attribute ("type", attribute_names, attribute_values);
offset = find_attribute ("offset", attribute_names, attribute_values); offset = find_attribute ("offset", attribute_names, attribute_values);
if (type == NULL) if (type == NULL)
MISSING_ATTRIBUTE (error, element_name, "type"); {
MISSING_ATTRIBUTE (error, element_name, "type");
return FALSE;
}
else if (offset == NULL) else if (offset == NULL)
MISSING_ATTRIBUTE (error, element_name, "offset"); {
MISSING_ATTRIBUTE (error, element_name, "offset");
return FALSE;
}
else
{ {
((GIdlNodeUnion *)ctx->current_node)->discriminator_type ((GIdlNodeUnion *)ctx->current_node)->discriminator_type
= parse_type (type); = parse_type (type);
......
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