Summary: | new XSSFWorkbook(pkg) corrupts Excel file | ||
---|---|---|---|
Product: | POI | Reporter: | est412 <est412> |
Component: | XSSF | Assignee: | POI Developers List <dev> |
Status: | RESOLVED WORKSFORME | ||
Severity: | normal | ||
Priority: | P2 | ||
Version: | 3.9-FINAL | ||
Target Milestone: | --- | ||
Hardware: | PC | ||
OS: | All | ||
Attachments: |
Corrupted file
Initial and rezulting test files |
Are you able to work out how the files differ? (You'll probably need to unzip both, then do a whitespace ignoring diff / xmllint -format then diff to work out the changes) Created attachment 30348 [details]
Initial and rezulting test files
Unfortunately I not feel qualified enough to diff this files. Attaching all of it instead. I think this was fixed a long time ago. Nowadays you can also use open(String path, PackageAccess access) with PackageAccess.READ to avoid any writing back of the file. Please reopen or submit a new bug report if there is still a problem with the latest version of POI. |
Created attachment 30347 [details] Corrupted file Hello! This simple piece of code corrupts normal *.xlsx file. ------ pkg = OPCPackage.open(args[0]); wb = new XSSFWorkbook(pkg); pkg.close(); ------ Without statement wb = new XSSFWorkbook(pkg); *.xlsx file remains good. Corrupted *.xlsx attached. Thanx in advance!