poi-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cen...@apache.org
Subject svn commit: r1731560 - /poi/trunk/src/java/org/apache/poi/poifs/filesystem/NPOIFSFileSystem.java
Date Sun, 21 Feb 2016 20:41:57 GMT
Author: centic
Date: Sun Feb 21 20:41:56 2016
New Revision: 1731560

URL: http://svn.apache.org/viewvc?rev=1731560&view=rev
Log:
Include stacktrace of inner exception when block-positions are invalid in POIFSFileSystem

Modified:
    poi/trunk/src/java/org/apache/poi/poifs/filesystem/NPOIFSFileSystem.java

Modified: poi/trunk/src/java/org/apache/poi/poifs/filesystem/NPOIFSFileSystem.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/java/org/apache/poi/poifs/filesystem/NPOIFSFileSystem.java?rev=1731560&r1=1731559&r2=1731560&view=diff
==============================================================================
--- poi/trunk/src/java/org/apache/poi/poifs/filesystem/NPOIFSFileSystem.java (original)
+++ poi/trunk/src/java/org/apache/poi/poifs/filesystem/NPOIFSFileSystem.java Sun Feb 21 20:41:56
2016
@@ -483,7 +483,9 @@ public class NPOIFSFileSystem extends Bl
        try {
            return _data.read(bigBlockSize.getBigBlockSize(), startAt);
        } catch (IndexOutOfBoundsException e) {
-           throw new IndexOutOfBoundsException("Block " + offset + " not found - " + e);
+           IndexOutOfBoundsException wrapped = new IndexOutOfBoundsException("Block " + offset
+ " not found");
+           wrapped.initCause(e);
+           throw wrapped;
        }
     }
     



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@poi.apache.org
For additional commands, e-mail: commits-help@poi.apache.org


Mime
View raw message