gtk-builder-tool: Avoid a crash with <placeholder/>

Not sure we can do much with a ui file that has
<placeholder/> elements littered throughout. But
at least we can avoid crashing while trying to
convert it.

Fixes: #3781
This commit is contained in:
Matthias Clasen 2021-03-23 15:24:30 -04:00
parent 610ba0e764
commit 6a66ccd3e6

View File

@ -944,6 +944,8 @@ rewrite_notebook_page (Element *child, Element *tab, MyParserData *data)
object = elt;
else if (g_str_equal (elt->element_name, "packing"))
packing = elt;
else if (g_str_equal (elt->element_name, "placeholder"))
return child;
}
if (!packing && !tab)