Author: yegor
Date: Sat Dec 11 13:48:18 2010
New Revision: 1044655
URL: http://svn.apache.org/viewvc?rev=1044655&view=rev
Log:
mark GutsRecord as terminating row blocks, prevent exception when reading
workbooks with unexpected GutsRecords, see Bugzilla 50426
Added:
poi/trunk/test-data/spreadsheet/50426.xls (with props)
Modified:
poi/trunk/src/documentation/content/xdocs/status.xml
poi/trunk/src/java/org/apache/poi/hssf/model/RecordOrderer.java
poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestBugs.java
Modified: poi/trunk/src/documentation/content/xdocs/status.xml
URL:
http://svn.apache.org/viewvc/poi/trunk/src/documentation/content/xdocs/status.xml?rev=1044655&r1=1044654&r2=1044655&view=diff
==============================================================================
--- poi/trunk/src/documentation/content/xdocs/status.xml (original)
+++ poi/trunk/src/documentation/content/xdocs/status.xml Sat Dec 11 13:48:18
2010
@@ -34,6 +34,7 @@
<changes>
<release version="3.8-beta1" date="2010-??-??">
+ <action dev="POI-DEVELOPERS" type="fix">50246 - Properly position
GutsRecord when reading HSSF workbooks</action>
<action dev="POI-DEVELOPERS" type="add">48539 - Added
implementation for MROUND(), VAR() and VARP()</action>
<action dev="POI-DEVELOPERS" type="add">50446 - Code cleanup and
optimizations to keep some IDE quiet</action>
<action dev="POI-DEVELOPERS" type="add">50437 - Support passing
ranges to NPV()</action>
Modified: poi/trunk/src/java/org/apache/poi/hssf/model/RecordOrderer.java
URL:
http://svn.apache.org/viewvc/poi/trunk/src/java/org/apache/poi/hssf/model/RecordOrderer.java?rev=1044655&r1=1044654&r2=1044655&view=diff
==============================================================================
--- poi/trunk/src/java/org/apache/poi/hssf/model/RecordOrderer.java (original)
+++ poi/trunk/src/java/org/apache/poi/hssf/model/RecordOrderer.java Sat Dec 11
13:48:18 2010
@@ -417,6 +417,7 @@ final class RecordOrderer {
case ObjRecord.sid:
case TextObjectRecord.sid:
+ case GutsRecord.sid: // see Bugzilla 50426
case WindowOneRecord.sid:
// should really be part of workbook stream,
but some apps seem to put this before WINDOW2
case WindowTwoRecord.sid:
Modified: poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestBugs.java
URL:
http://svn.apache.org/viewvc/poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestBugs.java?rev=1044655&r1=1044654&r2=1044655&view=diff
==============================================================================
--- poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestBugs.java
(original)
+++ poi/trunk/src/testcases/org/apache/poi/hssf/usermodel/TestBugs.java Sat Dec
11 13:48:18 2010
@@ -1894,4 +1894,9 @@ if(1==2) {
HSSFWorkbook wb = openSample("50020.xls");
writeOutAndReadBack(wb);
}
+
+ public void test50426() throws Exception {
+ HSSFWorkbook wb = openSample("50426.xls");
+ writeOutAndReadBack(wb);
+ }
}
Added: poi/trunk/test-data/spreadsheet/50426.xls
URL:
http://svn.apache.org/viewvc/poi/trunk/test-data/spreadsheet/50426.xls?rev=1044655&view=auto
==============================================================================
Binary file - no diff available.
Propchange: poi/trunk/test-data/spreadsheet/50426.xls
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]