I have an xml file that looks like the following
<siteinfo>
...
</siteinfo>
<page>
<title>...</title>
<revision>
...
<revision>
</page>
It does not have a root/enclosing node so I get the "extra content at end of document" on running my program. After opening the file for parsing using libxml, is there a way to easily add this root/enclosing node to the parse tree?