mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-12-26 15:36:14 +01:00
repository: Ensure error is set if we're parsing a malformed file
https://bugzilla.gnome.org/show_bug.cgi?id=661951
This commit is contained in:
parent
a714bef965
commit
4359a037db
@ -3511,10 +3511,11 @@ _g_ir_parser_parse_string (GIrParser *parser,
|
||||
if (ctx.modules)
|
||||
return ctx.modules->data;
|
||||
|
||||
g_set_error (error,
|
||||
G_MARKUP_ERROR,
|
||||
G_MARKUP_ERROR_INVALID_CONTENT,
|
||||
"Expected namespace element in the gir file");
|
||||
if (error && *error == NULL)
|
||||
g_set_error (error,
|
||||
G_MARKUP_ERROR,
|
||||
G_MARKUP_ERROR_INVALID_CONTENT,
|
||||
"Expected namespace element in the gir file");
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user