Uploaded image for project: 'Xerces2-J'
  1. Xerces2-J
  2. XERCESJ-1694

Avoid stack overflow when using xpointer between two resources

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • None
    • None
    • SAX
    • None

    Description

      Let' say I have two documents:

      1) "a.xml":

      <book xmlns="http://docbook.org/ns/docbook"
          xmlns:xlink="http://www.w3.org/1999/xlink"
          xmlns:xi="http://www.w3.org/2001/XInclude"
          xml:id="a-book"
          version="5.0">
          <title>A</title>
          <chapter xml:id="a-chapter">
              <title>a chapter</title>
              <para>foo</para>
          </chapter>
          <xi:include href="b.xml" xpointer="b-chapter"/>
      </book>

      2) "b.xml":

      <book xmlns="http://docbook.org/ns/docbook"
          xmlns:xlink="http://www.w3.org/1999/xlink"
          xmlns:xi="http://www.w3.org/2001/XInclude"
          xml:id="b-book"
          version="5.0">
          <title>B</title>
          <chapter xml:id="b-chapter">
              <title>b chapter</title>
              <para>foo</para>
          </chapter>
          <xi:include href="a.xml" xpointer="a-chapter"/>
      </book>

      When using a SAX parser to parse "a.xml" a stack overflow occurs although according to the XInclude specs this is a legal situation, the xpointer parts to a part of b.xml.

      Attachments

        Activity

          People

            Unassigned Unassigned
            radu_coravu Radu Coravu
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: