https://bz.apache.org/bugzilla/show_bug.cgi?id=58779
Bug ID: 58779
Summary: Closing an XSSFWorkbook that was created with
WorkbookFactory modifies the file
Product: POI
Version: 3.14-dev
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P2
Component: SS Common
Assignee: [email protected]
Reporter: [email protected]
As noted in TestWorkbookFactory.java [1], XSSFWorkbooks that were opened with
WorkbookFactory and were not opened in read-only mode will modify the file upon
calling wb.close(), even if no changes were made to the workbook after creating
the XSSFWorkbook object.
To reproduce this problem, replace any `revert(wb)` with `wb.close()` in
TestWorkbookFactory.java and run TestWorkbookFactory.java. After running this
test, the SampleSS.xlsx file will have changed, as evidenced by "svn status
test-data/spreadsheet/SampleSS.xlsx"
[1]
http://svn.apache.org/viewvc/poi/trunk/src/ooxml/testcases/org/apache/poi/ss/TestWorkbookFactory.java?revision=1722078&view=markup
--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]