diff options
author | Caolán McNamara <caolan.mcnamara@collabora.com> | 2024-12-03 12:54:24 +0000 |
---|---|---|
committer | Caolán McNamara <caolan.mcnamara@collabora.com> | 2024-12-12 17:08:35 +0100 |
commit | a4cc73f644f3cb85a5ae4a62b23f7a6b088143a6 (patch) | |
tree | 7a1618f794eeaad3f984113e1337da75e6abcbf6 | |
parent | 565605f791bea50abf5fd07855882b1a445b28fd (diff) |
crashtesting: fix failure of forum-en-13617.odt to reload from .doc
Change-Id: I907e282c9e7b75abca9a4c91ba12a2c57fc45f40
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/177733
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Tested-by: Jenkins
(cherry picked from commit 63594c62024b894251e1c88d5f65980c553dec4e)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/177752
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
(cherry picked from commit 0ded71cc45edd4fb372f1c77857178597f949fbe)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/177761
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
Tested-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
-rw-r--r-- | starmath/source/mathtype.cxx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/starmath/source/mathtype.cxx b/starmath/source/mathtype.cxx index 64989e7993ca..d9b805630502 100644 --- a/starmath/source/mathtype.cxx +++ b/starmath/source/mathtype.cxx @@ -3147,6 +3147,7 @@ void MathType::HandleMath(SmNode *pNode) void MathType::HandleAttributes(SmNode *pNode,int nLevel) { + sal_uInt64 nOldInsertion = nInsertion; int nOldPending = 0; SmNode *pTemp = nullptr; SmTextNode *pIsText = nullptr; @@ -3220,8 +3221,7 @@ void MathType::HandleAttributes(SmNode *pNode,int nLevel) if ((nInsertion != 0) && nullptr != (pTemp = pNode->GetSubNode(0))) { auto nPos = pS->Tell(); - nInsertion--; - pS->Seek(nInsertion); + pS->Seek(nInsertion - 1); switch(pTemp->GetToken().eType) { case TACUTE: //Not Exportable @@ -3274,6 +3274,7 @@ void MathType::HandleAttributes(SmNode *pNode,int nLevel) pS->Seek(nPos); } } + nInsertion = nOldInsertion; } void MathType::HandleText(SmNode *pNode) |