diff options
-rw-r--r-- | sw/source/core/access/accfrmobj.cxx | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/sw/source/core/access/accfrmobj.cxx b/sw/source/core/access/accfrmobj.cxx index cf3e29520926..5b590787473a 100644 --- a/sw/source/core/access/accfrmobj.cxx +++ b/sw/source/core/access/accfrmobj.cxx @@ -367,10 +367,14 @@ const SwFrame* SwAccessibleChild::GetParent( const bool bInPagePreview ) const else { // In any other case the parent is the root frm - if( bInPagePreview ) - pParent = pContact->GetAnchorFrame()->FindPageFrame(); - else - pParent = pContact->GetAnchorFrame()->getRootFrame(); + SwFrame const*const pAnchor(pContact->GetAnchorFrame()); + if (pAnchor) // null if object removed from layout + { + if (bInPagePreview) + pParent = pAnchor->FindPageFrame(); + else + pParent = pAnchor->getRootFrame(); + } } } } |