[Libreoffice-commits] core.git: starmath/source

Caolán McNamara caolanm at redhat.com
Tue Dec 5 09:12:50 UTC 2017


 starmath/source/mathtype.cxx |    2 ++
 1 file changed, 2 insertions(+)

New commits:
commit 0722363c2b8e5a15397233fb21537508780d9585
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Mon Dec 4 21:13:26 2017 +0000

    ofz: infinite loop
    
    Change-Id: Ie2148fd0048c6894e1b317dd2a4f2533ff2e1814
    Reviewed-on: https://gerrit.libreoffice.org/45827
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/starmath/source/mathtype.cxx b/starmath/source/mathtype.cxx
index 000d5878ed5b..e055cd951ee2 100644
--- a/starmath/source/mathtype.cxx
+++ b/starmath/source/mathtype.cxx
@@ -2749,6 +2749,8 @@ void MathType::HandleEmblishments()
     do
     {
         pS->ReadUChar( nEmbel );
+        if (!pS->good())
+            break;
         switch (nEmbel)
         {
         case 0x02:


More information about the Libreoffice-commits mailing list