Apply patch from bug #51974 - Avoid HWPF issue when identifying the picture type
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1183645 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
32ffb44def
commit
d71f80e6a1
@ -34,6 +34,7 @@
|
||||
|
||||
<changes>
|
||||
<release version="3.8-beta5" date="2011-??-??">
|
||||
<action dev="poi-developers" type="fix">51974 - Avoid HWPF issue when identifying the picture type</action>
|
||||
<action dev="poi-developers" type="fix">52035 - Fix signed issue with very large word 6 files</action>
|
||||
<action dev="poi-developers" type="fix">51949 - Avoid NPE on double close of ZipFileZipEntrySource</action>
|
||||
<action dev="poi-developers" type="fix">51950 - XWPF fix for footnotes not always being present in a document</action>
|
||||
|
@ -432,7 +432,9 @@ public final class Picture
|
||||
*/
|
||||
public byte[] getRawContent()
|
||||
{
|
||||
if ( _picfAndOfficeArtData.getBlipRecords().size() != 1 )
|
||||
if ( _picfAndOfficeArtData == null ||
|
||||
_picfAndOfficeArtData.getBlipRecords()== null ||
|
||||
_picfAndOfficeArtData.getBlipRecords().size() != 1 )
|
||||
return new byte[0];
|
||||
|
||||
EscherRecord escherRecord = _picfAndOfficeArtData.getBlipRecords().get(
|
||||
@ -516,7 +518,9 @@ public final class Picture
|
||||
|
||||
public PictureType suggestPictureType()
|
||||
{
|
||||
if ( _picfAndOfficeArtData.getBlipRecords().size() != 1 )
|
||||
if ( _picfAndOfficeArtData == null ||
|
||||
_picfAndOfficeArtData.getBlipRecords()== null ||
|
||||
_picfAndOfficeArtData.getBlipRecords().size() != 1 )
|
||||
return PictureType.UNKNOWN;
|
||||
|
||||
EscherRecord escherRecord = _picfAndOfficeArtData.getBlipRecords().get(
|
||||
|
Loading…
Reference in New Issue
Block a user