aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/testcases/org/apache/poi/hssf/data/43251.xlsbin0 -> 166400 bytes
-rw-r--r--src/testcases/org/apache/poi/hssf/usermodel/TestBugs.java14
2 files changed, 14 insertions, 0 deletions
diff --git a/src/testcases/org/apache/poi/hssf/data/43251.xls b/src/testcases/org/apache/poi/hssf/data/43251.xls
new file mode 100644
index 0000000000..abc476ab0f
--- /dev/null
+++ b/src/testcases/org/apache/poi/hssf/data/43251.xls
Binary files differ
diff --git a/src/testcases/org/apache/poi/hssf/usermodel/TestBugs.java b/src/testcases/org/apache/poi/hssf/usermodel/TestBugs.java
index e7eff83e62..b534a8bbfb 100644
--- a/src/testcases/org/apache/poi/hssf/usermodel/TestBugs.java
+++ b/src/testcases/org/apache/poi/hssf/usermodel/TestBugs.java
@@ -1137,6 +1137,20 @@ extends TestCase {
}
/**
+ * Something up with the FileSharingRecord
+ */
+ public void test43251() throws Exception {
+ FileInputStream in = new FileInputStream(new File(cwd, "43251.xls"));
+
+ // Used to blow up with an IllegalArgumentException
+ // when creating a FileSharingRecord
+ HSSFWorkbook wb = new HSSFWorkbook(in);
+ in.close();
+
+ assertEquals(1, wb.getNumberOfSheets());
+ }
+
+ /**
* Crystal reports generates files with short
* StyleRecords, which is against the spec
*/