summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2014-10-06 15:59:09 +0100
committerMiklos Vajna <vmiklos@collabora.co.uk>2014-10-06 15:50:12 +0000
commit2a1a50b1d565270327a213f4e237b9655824a872 (patch)
tree47e0495d3fc8b8db11854add4e9c78e4600ea013
parent7a859ef06fa26b4ec4f774d6a91d18d5375e00d1 (diff)
Resolves: fdo#84588 loop in TableInfo::getNextNode
Change-Id: I5bb44dc94041c3b3cd9d80ba125594a48c9c921f (cherry picked from commit f0859c4eae0f567393811c308074723329f1faab) Reviewed-on: https://gerrit.libreoffice.org/11828 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Miklos Vajna <vmiklos@collabora.co.uk>
-rw-r--r--sw/source/filter/ww8/wrtww8.cxx8
1 files changed, 7 insertions, 1 deletions
diff --git a/sw/source/filter/ww8/wrtww8.cxx b/sw/source/filter/ww8/wrtww8.cxx
index 409eb82a2af4..f52a273aacb3 100644
--- a/sw/source/filter/ww8/wrtww8.cxx
+++ b/sw/source/filter/ww8/wrtww8.cxx
@@ -2643,9 +2643,15 @@ void MSWordExportBase::WriteText()
if ( pNd == &pNd->GetNodes().GetEndOfContent() )
break;
- SwNode * pCurrentNode = &pCurPam->GetPoint()->nNode.GetNode();
+ const SwNode * pCurrentNode = &pCurPam->GetPoint()->nNode.GetNode();
const SwNode * pNextNode = mpTableInfo->getNextNode(pCurrentNode);
+ if (pCurrentNode == pNextNode)
+ {
+ SAL_WARN("sw.ww8", "loop in TableInfo");
+ pNextNode = NULL;
+ }
+
if (pNextNode != NULL)
pCurPam->GetPoint()->nNode = SwNodeIndex(*pNextNode);
else