summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2019-07-26 09:22:53 +0100
committerCaolán McNamara <caolanm@redhat.com>2019-07-26 17:36:27 +0200
commitf9190ae607a5766a087b8ed5d7ac29ec8a3272c9 (patch)
treeb6ae08797771fcd3ae28881a51b264e7f7dad096
parentf501519a2d14684c63edbfcfa3362cddad9f4ec9 (diff)
cid#1448362 silence Dereference null return value
Change-Id: I6b24a10bb2cd67d9750702a43d15162fb5347d76 Reviewed-on: https://gerrit.libreoffice.org/76366 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r--sd/source/ui/func/fupage.cxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/sd/source/ui/func/fupage.cxx b/sd/source/ui/func/fupage.cxx
index ac3512ad5165..ae543ff9464f 100644
--- a/sd/source/ui/func/fupage.cxx
+++ b/sd/source/ui/func/fupage.cxx
@@ -370,7 +370,9 @@ const SfxItemSet* FuPage::ExecuteDialog(weld::Window* pParent, SfxRequest& rReq)
}
// if the background for this page was set to invisible, the background-object has to be deleted, too.
- if( ( pTempSet->GetItem<XFillStyleItem>( XATTR_FILLSTYLE )->GetValue() == drawing::FillStyle_NONE ) ||
+ const XFillStyleItem* pTempFillStyleItem = pTempSet->GetItem<XFillStyleItem>(XATTR_FILLSTYLE);
+ assert(pTempFillStyleItem);
+ if( ( pTempFillStyleItem->GetValue() == drawing::FillStyle_NONE ) ||
( ( pTempSet->GetItemState( XATTR_FILLSTYLE ) == SfxItemState::DEFAULT ) &&
( aMergedAttr.GetItem<XFillStyleItem>( XATTR_FILLSTYLE )->GetValue() == drawing::FillStyle_NONE ) ) )
mbPageBckgrdDeleted = true;