WMF import: restore support for the ImplReadDIB(bFileHeader=false) version
Regression from commit f7799c9317
(Resolves: #i124467# add check for image data offset..., 2014-03-28).
Change-Id: I71e78aefca2ca5b07f763ec798226b9bb39a5254
This commit is contained in:
BIN
vcl/qa/cppunit/graphicfilter/data/wmf/pass/noheader.wmf
Normal file
BIN
vcl/qa/cppunit/graphicfilter/data/wmf/pass/noheader.wmf
Normal file
Binary file not shown.
@@ -605,7 +605,9 @@ bool ImplReadDIBBody( SvStream& rIStm, Bitmap& rBmp, Bitmap* pBmpAlpha, sal_uLon
|
||||
|
||||
if(ImplReadDIBInfoHeader(rIStm, aHeader, bTopDown) && aHeader.nWidth && aHeader.nHeight && aHeader.nBitCount)
|
||||
{
|
||||
if (aHeader.nSize > nOffset)
|
||||
// In case ImplReadDIB() didn't call ImplReadDIBFileHeader() before
|
||||
// this method, nOffset is 0, that's OK.
|
||||
if (nOffset && aHeader.nSize > nOffset)
|
||||
{
|
||||
// Header size claims to extend into the image data.
|
||||
// Looks like an error.
|
||||
|
Reference in New Issue
Block a user