Re: [xml] Regarding SVN Revision 3729 in tree.c

On Tue, Apr 08, 2008 at 01:19:59PM +0800, Ashwin wrote:


I think the change in xmlNewPropInternal(tree.c Revision 3729) to take care
of memory failure is incorrect. The coditioon to free name is currently:-


if ((eatname == 1) &&

            ((node->doc == NULL) ||

             (!(xmlDictOwns(node->doc->dict, name) == 0))))



According to the above condition name will be freed when it belongs to the
dictionary which I believe is incorrect. I think the condition should be


if ((eatname == 1) &&

            ((node->doc == NULL) ||

             ((xmlDictOwns(node->doc->dict, name) == 0))))


if ((eatname == 1) &&

            ((node->doc == NULL) ||

             (!(xmlDictOwns(node->doc->dict, name))))---This is the
statement used in xmlNewDocNodeEatName

  yes bug from me, i don't know why i used a different expression there
than when I modified xmlNewDocNodeEatName(),

  fixed in SVN, thanks for the heads up !


Red Hat Virtualization group
Daniel Veillard      | virtualization library
veillard redhat com  | libxml GNOME XML XSLT toolkit | Rpmfind RPM search engine

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