summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sfx2/source/dialog/templdlg.cxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/sfx2/source/dialog/templdlg.cxx b/sfx2/source/dialog/templdlg.cxx
index ecc4d4192d1e..cbd856ff617a 100644
--- a/sfx2/source/dialog/templdlg.cxx
+++ b/sfx2/source/dialog/templdlg.cxx
@@ -1245,6 +1245,8 @@ void SfxCommonTemplateDialog_Impl::FillTreeBox()
if(pStyleSheetPool && nActFamily != 0xffff)
{
const SfxStyleFamilyItem *pItem = GetFamilyItem_Impl();
+ if(!pItem)
+ return;
pStyleSheetPool->SetSearchMask(pItem->GetFamily(), SFXSTYLEBIT_ALL_VISIBLE);
StyleTreeArr_Impl aArr;
SfxStyleSheetBase *pStyle = pStyleSheetPool->First();
@@ -1589,7 +1591,7 @@ void SfxCommonTemplateDialog_Impl::Update_Impl()
// other filters for automatic
CheckItem( nActFamily, sal_True );
const SfxStyleFamilyItem *pStyleItem = GetFamilyItem_Impl();
- if ( 0 == pStyleItem->GetFilterList()[ nActFilter ]->nFlags
+ if ( pStyleItem && 0 == pStyleItem->GetFilterList()[ nActFilter ]->nFlags
&& nAppFilter != pItem->GetValue())
{
nAppFilter = pItem->GetValue();