Re: [xml] SAX2.c xmlSAX2AttributeNs problem with doc



On Wed, Oct 06, 2004 at 11:13:38AM -0400, Rob Richards wrote:
I hit a problem where the attribute value (text node) doesnt get the correct
doc set.
Sorry, dont have a self contained example as I pulled thise from various
functions which demonstrates the problem.

I am doing the following (where doc is an existing doc and nodep is an
element in the doc:
data contains: <a href='&amp;'></a>

  Funny I did hit something exactly similar as I'm adding tree checking
while going though the regression tests. Apparently I fixed it differently.

xmlParseBalancedChunkMemory(doc, NULL, NULL, 0, data, &lst);
xmlAddChildList(nodep,lst);

The text node - & - retains the document ctxt->myDoc rather than the doc
passed into xmlParseBalancedChunkMemory

not sure which is the best/correct fix to use though (the differences being
which document an error is associated with if one occurs as well as it
doesnt look like standalone is set on ctxt->myDoc if xmlGetDocEntity were to
be called).

  patch makes sense, applied thanks,

Daniel

-- 
Daniel Veillard      | Red Hat Desktop team http://redhat.com/
veillard redhat com  | libxml GNOME XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]