diff options
author | Mike Hommey <mh@glandium.org> | 2004-07-06 12:57:17 +0000 |
---|---|---|
committer | Mike Hommey <mh@glandium.org> | 2004-07-06 12:57:17 +0000 |
commit | c14c53a3645d81281058d4bb4cff24fa8d6faf33 (patch) | |
tree | 29bccc2e7499af078a3d1cdcfb517a1dee891be5 /relaxng.c | |
parent | d4e028c96af89ade493b440d4f2de6b684c03a06 (diff) | |
download | libxml2-c14c53a3645d81281058d4bb4cff24fa8d6faf33.tar.gz |
Load /tmp/tmp.DIvcnD/libxml2-2.6.11 intoupstream/2.6.11
packages/libxml2/branches/upstream/current.
Diffstat (limited to 'relaxng.c')
-rw-r--r-- | relaxng.c | 14 |
1 files changed, 14 insertions, 0 deletions
@@ -7182,6 +7182,20 @@ xmlRelaxNGCleanupTree(xmlRelaxNGParserCtxtPtr ctxt, xmlNodePtr root) } if (ns != NULL) xmlFree(ns); + /* + * Since we are about to delete cur, if it's nsDef is non-NULL we + * need to preserve it (it contains the ns definitions for the + * children we just moved). We'll just stick it on to the end + * of cur->parent's list, since it's never going to be re-serialized + * (bug 143738). + */ + if (cur->nsDef != NULL) { + xmlNsPtr parDef = (xmlNsPtr)&cur->parent->nsDef; + while (parDef->next != NULL) + parDef = parDef->next; + parDef->next = cur->nsDef; + cur->nsDef = NULL; + } delete = cur; goto skip_children; } |