summaryrefslogtreecommitdiffstats
path: root/sw/source/core/layout/pagechg.cxx
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2016-09-03 18:59:14 +0100
committerCaolán McNamara <caolanm@redhat.com>2016-09-03 18:59:14 +0100
commitdca56edbb1a0feae7cc8fa090e298ec38ecb5602 (patch)
tree8f51beb7ab756640ac6c241c8211e38b7ae52ac0 /sw/source/core/layout/pagechg.cxx
parentcoverity#1372443 Unchecked return value (diff)
downloadcore-dca56edbb1a0feae7cc8fa090e298ec38ecb5602.tar.gz
core-dca56edbb1a0feae7cc8fa090e298ec38ecb5602.zip
coverity#1372444 Dereference after null check
Change-Id: Ia756854e1f4a848b62dda38c9667ddd032989605
Diffstat (limited to 'sw/source/core/layout/pagechg.cxx')
-rw-r--r--sw/source/core/layout/pagechg.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/sw/source/core/layout/pagechg.cxx b/sw/source/core/layout/pagechg.cxx
index dd2aab0f59a7..e795c1d8bf0f 100644
--- a/sw/source/core/layout/pagechg.cxx
+++ b/sw/source/core/layout/pagechg.cxx
@@ -1050,7 +1050,7 @@ void SwFrame::CheckPageDescs( SwPageFrame *pStart, bool bNotifyFields, SwPageFra
{
SAL_INFO( "sw.pageframe", "CheckPageDescs phys: " << pPage->GetPhyPageNum()
<< " c: 1+3 - skip next page of p: " << pPage );
- if (pPage->GetPageDesc() != pPrevPage->GetPageDesc())
+ if (pPrevPage && pPage->GetPageDesc() != pPrevPage->GetPageDesc())
pPage->SetPageDesc( pPrevPage->GetPageDesc(), nullptr );
// We can skip the next page, as all checks were already done!
pPage = static_cast<SwPageFrame*>(pNextPage->GetNext());