Uploaded image for project: 'XMLBeans'
  1. XMLBeans
  2. XMLBEANS-291

java.lang.ArrayIndexOutOfBoundsException: 16384

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • Version 2.2
    • Version 2.3
    • None
    • None
    • Apache Tomcat v5.5.17, JDK version 5 update 8, Windows XP Professional

    Description

      I believe I am running into the same problem described here:

      http://issues.apache.org/jira/browse/XMLBEANS-87

      The error is associated with the _in not being updated correctly. The output below is from a diagnostic System.err.println added to the TextSaver.replace method and TextServer.entitizeAttrValue method:

      entitizeAttrValue(): i = 16347, _buf = 16384, _in = 16380, _out = 8192, _free = 8196, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16348, _buf = 16384, _in = 16380, _out = 8192, _free = 8196, _lastEmitCch = 54, _lastEmitIn = 16326
      replace(): dCch = 4, i = 16348, _buf.length = 16384, _in = 16380, _out = 8192, _free = 8196, replacement = &
      entitizeAttrValue(): i = 16353, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16354, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16355, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16356, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16357, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16358, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16359, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16360, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16361, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16362, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16363, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16364, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16365, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16366, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16367, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16368, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16369, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16370, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16371, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16372, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16373, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16374, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16375, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16376, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16377, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16378, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16379, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16380, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16381, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16382, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 16383, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326
      entitizeAttrValue(): i = 0, _buf.length = 16384, _in = 16384, _out = 8192, _free = 8192, _lastEmitCch = 54, _lastEmitIn = 16326

      java.lang.ArrayIndexOutOfBoundsException: 16384
      at org.apache.xmlbeans.impl.store.Saver$TextSaver.emit(Saver.java:1140)
      at org.apache.xmlbeans.impl.store.Saver$TextSaver.emitAttrHelper(Saver.java:990)
      at org.apache.xmlbeans.impl.store.Saver$TextSaver.emitElement(Saver.java:927)
      at org.apache.xmlbeans.impl.store.Saver.processElement(Saver.java:456)
      at org.apache.xmlbeans.impl.store.Saver.process(Saver.java:307)
      at org.apache.xmlbeans.impl.store.Saver$TextSaver.ensure(Saver.java:1547)
      at org.apache.xmlbeans.impl.store.Saver$TextSaver.read(Saver.java:1634)
      at org.apache.xmlbeans.impl.store.Saver$TextReader.read(Saver.java:2233)
      at org.apache.xmlbeans.impl.store.Cursor._save(Cursor.java:613)
      at org.apache.xmlbeans.impl.store.Cursor.save(Cursor.java:2562)
      at org.apache.xmlbeans.impl.values.XmlObjectBase.save(XmlObjectBase.java:183)
      at org.apache.xmlbeans.impl.values.XmlObjectBase.save(XmlObjectBase.java:195)

      Attachments

        Activity

          People

            Unassigned Unassigned
            fsiegrist42 Stuart Siegrist
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: