vcl/source/gdi/svmconverter.cxx |    6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

New commits:
commit 9e77785b6fcf5aed2a51b7cbbe1ccd5f5e266851
Author: Caolán McNamara <caol...@redhat.com>
Date:   Thu Mar 16 14:02:35 2017 +0000

    ofz#880 timeout loading svm
    
    Change-Id: I8b19a66a7cb8d4eda3774ddc32a43e8653e1c6a0

diff --git a/vcl/source/gdi/svmconverter.cxx b/vcl/source/gdi/svmconverter.cxx
index 72efcfa7722c..55e1faf5b7c1 100644
--- a/vcl/source/gdi/svmconverter.cxx
+++ b/vcl/source/gdi/svmconverter.cxx
@@ -1034,7 +1034,11 @@ void SVMConverter::ImplConvertFromSVM1( SvStream& rIStm, 
GDIMetaFile& rMtf )
                         ImplReadUnicodeComment( nUnicodeCommentStreamPos, 
rIStm, aStr );
                     rMtf.AddAction( new MetaStretchTextAction( aPt, nWidth, 
aStr, nIndex, nLen ) );
                 }
-                rIStm.Seek( nActBegin + nActionSize );
+
+                if (nActionSize < 28)
+                    rIStm.SetError(SVSTREAM_FILEFORMAT_ERROR);
+                else
+                    rIStm.Seek(nActBegin + nActionSize);
             }
             break;
 
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to