[libxml2] Fix RELAX NG include bug #655288



commit d7eb9b5d47e1f5ea1c45db3a0ca5a1c8621cfb05
Author: Shaun McCance <shaunm gnome org>
Date:   Thu Aug 4 10:28:59 2011 -0400

    Fix RELAX NG include bug #655288
    
    When overriding during include, children of the root
    node are scanned. But the root node was gotten with
    doc->children, instead of xmlDocGetRootElement.

 relaxng.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/relaxng.c b/relaxng.c
index 6dbc499..a0518e2 100644
--- a/relaxng.c
+++ b/relaxng.c
@@ -1561,8 +1561,8 @@ xmlRelaxNGRemoveRedefine(xmlRelaxNGParserCtxtPtr ctxt,
                     href = xmlGetProp(tmp, BAD_CAST "href");
 #endif
                     if (xmlRelaxNGRemoveRedefine(ctxt, href,
-                                                 inc->doc->children->
-                                                 children, name) == 1) {
+                                                 xmlDocGetRootElement(inc->doc)->children,
+                                                 name) == 1) {
                         found = 1;
                     }
 #ifdef DEBUG_INCLUDE



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