Previously, property existence checks such as "'$attr$a' in node",
"'to' in node", or "'$tags$to' in node" created the property value and
never released it when no property descriptor was requested. A leaked
XMLNode also held a reference to its document, so the whole document
was never freed.
Also, qjs_xml_node_make() and qjs_xml_attr_make() incremented the
document reference count before creating the object, so a failed
JS_NewObjectClass() left the document permanently referenced.
The fix is to free the value when no descriptor is requested and to
take the document reference only after the object is created.