[Libreoffice-commits] core.git: starmath/source
Caolán McNamara
caolanm at redhat.com
Tue Dec 5 20:25:29 UTC 2017
starmath/source/mathmlimport.cxx | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
New commits:
commit 4ee1b8f144b90e3532adfac7e5e806552612472e
Author: Caolán McNamara <caolanm at redhat.com>
Date: Tue Dec 5 13:14:26 2017 +0000
ofz#4531 Bad-cast
Change-Id: I152c2e7fa09fc637b176482de9718cf03880c23e
Reviewed-on: https://gerrit.libreoffice.org/45875
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/mathmlimport.cxx b/starmath/source/mathmlimport.cxx
index 6e7001214541..87befa6fdc85 100644
--- a/starmath/source/mathmlimport.cxx
+++ b/starmath/source/mathmlimport.cxx
@@ -2647,7 +2647,7 @@ void SmXMLTableContext_Impl::EndElement()
for (auto i=nRows;i > 0;i--)
{
- SmStructureNode* pArray = static_cast<SmStructureNode *>(rNodeStack.front().release());
+ SmNode* pArray = rNodeStack.front().release();
rNodeStack.pop_front();
if (pArray->GetNumSubNodes() == 0)
{
@@ -2663,13 +2663,14 @@ void SmXMLTableContext_Impl::EndElement()
aRelationArray.resize(1);
aRelationArray[0] = pArray;
SmToken aDummy;
- pArray = new SmExpressionNode(aDummy);
- pArray->SetSubNodes(aRelationArray);
+ SmExpressionNode* pExprNode = new SmExpressionNode(aDummy);
+ pExprNode->SetSubNodes(aRelationArray);
+ pArray = pExprNode;
}
if (pArray->GetNumSubNodes() > nCols)
nCols = pArray->GetNumSubNodes();
- aReverseStack.push_front(std::unique_ptr<SmStructureNode>(pArray));
+ aReverseStack.push_front(std::unique_ptr<SmNode>(pArray));
}
aExpressionArray.resize(nCols*nRows);
size_t j=0;
More information about the Libreoffice-commits
mailing list