https://issues.apache.org/bugzilla/show_bug.cgi?id=52540
Bug #: 52540
Summary: [PATCH] Need to support docx files with multiple core
properties
Product: POI
Version: 3.8-dev
Platform: Macintosh
Status: NEW
Severity: normal
Priority: P2
Component: XWPF
AssignedTo: [email protected]
ReportedBy: [email protected]
Classification: Unclassified
Created attachment 28215
--> https://issues.apache.org/bugzilla/attachment.cgi?id=28215
Small document containing more than one core properties element.
In order to comply with rule M4.1 ("A format consumer shall consider
more than one core properties relationship for a package to be an
error"), POI throws an exception when you attempt to open a Word docx
file that violates this rule. Unfortunately, Word 2008 and 2011 for
Macintosh create, save, and open files with multiple core
properties. I do not have easy access to Windows versions of Word, so
I don't know what happens when this file is read into Word and saved
out again. This is using the latest 3.8beta5 version of POI. I have
attached a small Word docx file ("base.docx") that demonstrates the
problem.
I have created a patch that relaxes this compliance. Instead of
throwing an exception, I take the first core properties encountered in
the file and silently ignore any subsequent core properties in the file.
I completely understand if this patch is not accepted. I've modified
the code to explicitly violate a clear rule in the standard. But I
need to support my users, which means I need to support these
non-conforming files.
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- 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]