https://bz.apache.org/bugzilla/show_bug.cgi?id=65639

Todd Heidenthal <t.heident...@gtisoft.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |NEW

--- Comment #10 from Todd Heidenthal <t.heident...@gtisoft.com> ---
I came across the following when using ooxml 5.2.0 (didn't have the problem in
4.1.0)

BUG_REPORT: Uncaught org.apache.poi.util.RecordFormatException at
org.apache.poi.util.IOUtils.throwRFE(IOUtils.java:535) [Fri Feb 18 11:53:07 CST
2022]
org.apache.poi.util.RecordFormatException: Tried to allocate an array of length
197,775,541, but the maximum length for this record type is 100,000,000.
If the file is not corrupt, please open an issue on bugzilla to request 
increasing the maximum allowable size for this record type.
As a temporary workaround, consider setting a higher override value with
IOUtils.setByteArrayMaxOverride()

This was when loading an xlsx file.  My sample file is 38144 KB which is larger
than your system will allow to be updated.  If you can provide another way for
me to get it to you, I am happy to share.

I have used setByteArrayMaxOverride as a temporary workaround as suggested and
it only resulted in the following stack trace.

java.io.IOException: MaxLength (100000000) reached - stream seems to be
invalid.
        at org.apache.poi.util.IOUtils.toByteArray(IOUtils.java:195)
        at
org.apache.poi.openxml4j.util.ZipArchiveFakeEntry.<init>(ZipArchiveFakeEntry.java:72)
        at
org.apache.poi.openxml4j.util.ZipInputStreamZipEntrySource.<init>(ZipInputStreamZipEntrySource.java:98)
        at org.apache.poi.openxml4j.opc.ZipPackage.<init>(ZipPackage.java:132)
        at org.apache.poi.openxml4j.opc.OPCPackage.open(OPCPackage.java:312)

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@poi.apache.org
For additional commands, e-mail: dev-h...@poi.apache.org

Reply via email to