Uploaded image for project: 'Xerces-C++'
  1. Xerces-C++
  2. XERCESC-1051

Crash when maxOccurs >= 200000

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.3.0
    • 3.0.0
    • None
    • Operating System: Windows NT/2K
      Platform: PC
    • 24703

    Description

      Parser crashes in ContentSpecNode.hpp: ContentSpecNode::~ContentSpecNode().

      Steps to reproduce:
      validate a xml file against a schema with an element having a maxOccurs >=
      200000.

      Assumed cause:
      Stack overfow

      Makeshift resolution:
      Set the repeat count to unbounded(-1), when maxOccurs > 500:

      inline void ContentSpecNode::setMaxOccurs(int max)
      {
      if(max > 500)
      max = -1;
      fMaxOccurs = max;
      }

      Attachments

        Activity

          People

            amassari Alberto Massari
            rast@gefeg.com Frank Rast
            Votes:
            2 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: