On Wed, Jul 13, 2005 at 10:31:08AM +0200, [EMAIL PROTECTED] wrote:
> My application needs to be able to do that even if "xmlNode" does not belong 
> to any DOM (that is, a subtree of nodes created by scratch). I tried to do 
> this:
> 
> // Create xpath evaluation context
> xpathCtx = xmlXPathNewContext(NULL);
> 
> and it seems to be working properly. 
> But I wonder, is that safe ?

  This should be safe as long as none of the XPath expressions need to
access the root, but this is a non-common situation so you are exposing
yourself to potential bugs that may have been unnoticed because everybody
tests with document where all nodes refers to a doc.
  I can't give a formal "this is safe" statement.

Daniel

-- 
Daniel Veillard      | Red Hat Desktop team http://redhat.com/
[EMAIL PROTECTED]  | libxml GNOME XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/
_______________________________________________
xml mailing list, project page  http://xmlsoft.org/
[email protected]
http://mail.gnome.org/mailman/listinfo/xml

Reply via email to