Kaydet (Commit) 53d879aa authored tarafından Caolán McNamara's avatar Caolán McNamara

coverity#1000605 Dereference after null check

Change-Id: I1b7404e04fd2a6c7100d663054a91da63edd0652
üst 1fca856a
......@@ -62,8 +62,13 @@ static sal_uInt16 nPgNum = 0;
bool SwView::IsDocumentBorder()
{
return GetDocShell()->GetCreateMode() == SFX_CREATE_MODE_EMBEDDED ||
m_pWrtShell->GetViewOptions()->getBrowseMode() ||
if (GetDocShell()->GetCreateMode() == SFX_CREATE_MODE_EMBEDDED)
return true;
if (!m_pWrtShell)
return false;
return m_pWrtShell->GetViewOptions()->getBrowseMode() ||
SVX_ZOOM_PAGEWIDTH_NOBORDER == (SvxZoomType)m_pWrtShell->GetViewOptions()->GetZoomType();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment