summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sw/source/core/doc/DocumentLayoutManager.cxx10
1 files changed, 5 insertions, 5 deletions
diff --git a/sw/source/core/doc/DocumentLayoutManager.cxx b/sw/source/core/doc/DocumentLayoutManager.cxx
index cb1ec6d98d27..17b5fb1e6923 100644
--- a/sw/source/core/doc/DocumentLayoutManager.cxx
+++ b/sw/source/core/doc/DocumentLayoutManager.cxx
@@ -509,11 +509,11 @@ SwFrameFormat *DocumentLayoutManager::CopyLayoutFormat(
// Link FLY and DRAW formats, so it becomes a text box
SdrObject* pNewObj = pDest->FindRealSdrObject();
- if (bIsGroupObj && pDest->FindRealSdrObject()
- && pDest->FindRealSdrObject()->getChildrenOfSdrObject()
- && (pDest->FindRealSdrObject()->getChildrenOfSdrObject()->GetObjCount() > it)
- && pDest->FindRealSdrObject()->getChildrenOfSdrObject()->GetObj(it))
- pNewObj = pDest->FindRealSdrObject()->getChildrenOfSdrObject()->GetObj(it);
+ if (bIsGroupObj && pNewObj
+ && pNewObj->getChildrenOfSdrObject()
+ && (pNewObj->getChildrenOfSdrObject()->GetObjCount() > it)
+ && pNewObj->getChildrenOfSdrObject()->GetObj(it))
+ pNewObj = pNewObj->getChildrenOfSdrObject()->GetObj(it);
pTextBoxNd->AddTextBox(pNewObj, pDestTextBox);
pDestTextBox->SetOtherTextBoxFormat(pTextBoxNd);
}