[Libreoffice-commits] core.git: Branch 'libreoffice-6-1' - editeng/source

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Fri Nov 9 13:23:35 UTC 2018


 editeng/source/rtf/svxrtf.cxx |   16 +---------------
 1 file changed, 1 insertion(+), 15 deletions(-)

New commits:
commit 86b30f05b41e751ca144796b61243e2ecaf56324
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Thu Nov 8 12:20:25 2018 +0000
Commit:     Xisco Faulí <xiscofauli at libreoffice.org>
CommitDate: Fri Nov 9 14:22:09 2018 +0100

    Resolves: tdf#121200 Revert "ofz#7802 infinite loop"
    
    This reverts commit 409441652af3df62e742b9d7a3d80cb6b15214af.
    
    Change-Id: Ifa7b5437a1d9024466f5769b14ad67ed8777e04a
    Reviewed-on: https://gerrit.libreoffice.org/63093
    Tested-by: Jenkins
    Reviewed-by: Xisco Faulí <xiscofauli at libreoffice.org>

diff --git a/editeng/source/rtf/svxrtf.cxx b/editeng/source/rtf/svxrtf.cxx
index 88a3a1c110bf..369995b1d293 100644
--- a/editeng/source/rtf/svxrtf.cxx
+++ b/editeng/source/rtf/svxrtf.cxx
@@ -356,10 +356,7 @@ void SvxRTFParser::ReadStyleTable()
             case RTF_CHRFMT:
             case RTF_BRDRDEF:
             case RTF_TABSTOPDEF:
-#ifndef NDEBUG
-                auto nEnteringToken = nToken;
-#endif
-                auto nEnteringIndex = m_nTokenIndex;
+
                 if( RTF_SWGDEFS & nToken)
                 {
                     if( RTF_IGNOREFLAG != GetStackPtr( -1 )->nTokenId )
@@ -371,17 +368,6 @@ void SvxRTFParser::ReadStyleTable()
                     }
                 }
                 ReadAttr( nToken, &pStyle->aAttrSet );
-                if (m_nTokenIndex == nEnteringIndex - 1)
-                {
-                    // we called SkipToken to go back one, but
-                    // ReadAttrs read nothing, so on next loop
-                    // of outer while we would end up in the
-                    // same state again (assert that)
-                    assert(nEnteringToken == GetNextToken());
-                    // and loop endlessly, skip format a token
-                    // instead to avoid that
-                    SkipToken(1);
-                }
                 break;
             }
             break;


More information about the Libreoffice-commits mailing list