projects
/
gtk4.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e230c9c
)
builderparser: Be more robust
author
Matthias Clasen
<mclasen@redhat.com>
Mon, 13 Dec 2021 19:44:40 +0000
(14:44 -0500)
committer
Matthias Clasen
<mclasen@redhat.com>
Mon, 13 Dec 2021 20:09:48 +0000
(15:09 -0500)
If a document contains no useful content,
just say so instead of crashing.
tools/gtk-builder-tool-simplify.c
patch
|
blob
|
history
diff --git
a/tools/gtk-builder-tool-simplify.c
b/tools/gtk-builder-tool-simplify.c
index bb8e1ebd625b0bb0bb107d41a270e59af867ffda..635b6332fab702baf10fef2d6efa0382cdf0d820 100644
(file)
--- a/
tools/gtk-builder-tool-simplify.c
+++ b/
tools/gtk-builder-tool-simplify.c
@@
-2301,6
+2301,12
@@
simplify_file (const char *filename,
return FALSE;
}
+ if (data.root == NULL)
+ {
+ g_printerr (_("Can't parse ā%sā\n"), filename);
+ return FALSE;
+ }
+
data.builder = gtk_builder_new ();
if (data.convert3to4)