poi-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject [Bug 58917] New: [Patch] AddContentType failing to add new content type to docx for JPEG/image if one already exists for jpg
Date Sun, 24 Jan 2016 11:20:51 GMT
https://bz.apache.org/bugzilla/show_bug.cgi?id=58917

            Bug ID: 58917
           Summary: [Patch] AddContentType failing to add new content type
                    to docx for JPEG/image if one already exists for jpg
           Product: POI
           Version: 3.14-dev
          Hardware: Other
                OS: All
            Status: NEW
          Severity: major
          Priority: P2
         Component: OPC
          Assignee: dev@poi.apache.org
          Reporter: Scull.sarah@gmail.com

Created attachment 33483
  --> https://bz.apache.org/bugzilla/attachment.cgi?id=33483&action=edit
file with fixed addContentType method

Our word document already had jpg's in it. Using poi we then tried to add a
jpg. Poi changed this to a JPEG and then did not add a new content type.

When poi saves an image in the media folder it stores jpg images as JPEGs.it
then checks to see if a media type of image/JPEG exists - which it does but for
extension jpg. Thus no new content type is added. The word doc is now corrupt.
Proposed change attached.

I put this in as major as it was a blocker for me. I realise that it won't be
for everyone.

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


Mime
View raw message