diff options
-rw-r--r-- | sw/source/core/layout/atrfrm.cxx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sw/source/core/layout/atrfrm.cxx b/sw/source/core/layout/atrfrm.cxx index 26b466588d35..15d2d309d571 100644 --- a/sw/source/core/layout/atrfrm.cxx +++ b/sw/source/core/layout/atrfrm.cxx @@ -2632,14 +2632,15 @@ void SwFrameFormat::SetFormatName( const OUString& rNewName, bool bBroadcast ) { if (SwFlyFrame* pSFly = SwIterator<SwFlyFrame, SwFormat>(*this).First()) { - if (pSFly->Lower() && !pSFly->Lower()->IsNoTextFrame()) + SwFrame *pSFlyLower = pSFly->Lower(); + if (pSFlyLower && !pSFlyLower->IsNoTextFrame()) { if (SwTextNode* pSwTxtNode = static_cast<SwTextFrame*>(pSFly->ContainsContent())->GetTextNodeFirst()) pSwTxtNode->resetAndQueueAccessibilityCheck(true); } else { - if (SwNode* pSwNode = static_cast<SwNoTextFrame*>(pSFly->Lower())->GetNode()) + if (SwNode* pSwNode = static_cast<SwNoTextFrame*>(pSFlyLower)->GetNode()) pSwNode->resetAndQueueAccessibilityCheck(true); } } |