[Libreoffice-commits] core.git: vcl/source
Caolán McNamara
caolanm at redhat.com
Mon May 15 11:57:36 UTC 2017
vcl/source/filter/wmf/enhwmf.cxx | 2 ++
1 file changed, 2 insertions(+)
New commits:
commit 81c36caa943691417b12677826b9b108bad098d5
Author: Caolán McNamara <caolanm at redhat.com>
Date: Mon May 15 12:55:05 2017 +0100
ofz#1612 avoid oom
Change-Id: I2e327ea449dad8ec88963b6b9429e478a3332e22
diff --git a/vcl/source/filter/wmf/enhwmf.cxx b/vcl/source/filter/wmf/enhwmf.cxx
index b55e969dbea5..22125d747dbe 100644
--- a/vcl/source/filter/wmf/enhwmf.cxx
+++ b/vcl/source/filter/wmf/enhwmf.cxx
@@ -545,6 +545,8 @@ void EnhWMFReader::ReadAndDrawPolyLine()
pWMF->SeekRel( 0x10 ); // TODO Skipping Bounds. A 128-bit WMF RectL object (specifies the bounding rectangle in device units.)
pWMF->ReadUInt32( nNumberOfPolylines );
pWMF->ReadUInt32( nCount ); // total number of points in all polylines
+ if (pWMF->Tell() >= nEndPos)
+ return;
// taking the amount of points of each polygon, retrieving the total number of points
if ( pWMF->good() &&
More information about the Libreoffice-commits
mailing list