On Tue, May 03, 2011 at 03:42:56PM -0400, Paul B. Cameron wrote: > I believe I'm able to answer my own questions: > > 1. Use xmlGetNodePath to build the node path instead of rolling a custom > function.
right ! > 2. There is no need to return a copy of a node retrieved by an XPath > evaluation - node pointers returned by the query point to the actual node > memory in the tree. These nodes do not become invalid when the query object > or context are freed. And right ! ... except for the nasty case of namespace nodes, where libxml2 model and XPath data model don't match and as a result the namespace nodes returned in an XPath query don't come from the tree (but are freed when the XPath object is freed). aniel -- Daniel Veillard | libxml Gnome XML XSLT toolkit http://xmlsoft.org/ [email protected] | Rpmfind RPM search engine http://rpmfind.net/ http://veillard.com/ | virtualization library http://libvirt.org/ _______________________________________________ xml mailing list, project page http://xmlsoft.org/ [email protected] http://mail.gnome.org/mailman/listinfo/xml
