summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2016-08-16 11:54:38 +0100
committerKatarina Behrens <Katarina.Behrens@cib.de>2016-08-16 12:33:08 +0000
commitd15b7eb6b4525283343b5030b3227c264ec8976b (patch)
tree2f4c7fffe0da60d68229cb0b2e69368002cd877e
parent834ae34d7f16f37078bf0065af8bff29f9d5c422 (diff)
Resolves: tdf#101165 crash on deselecting all filters
this affects 5-1, but not master because of 7967e5e51e5210b8c3d3dc63502bd7d875eb36b7 which changed the trigger in ScCheckListMenuWindow::setAllMemberState but lets fix it in master anyway in case there's another route in here Change-Id: I49162bb73bf6dbef5cff68d35d10da2c47d9f2b5 (cherry picked from commit b101ff56e874824fa9f0d37a8468b07dbf3d002c) Reviewed-on: https://gerrit.libreoffice.org/28164 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
-rw-r--r--sc/source/ui/cctrl/checklistmenu.cxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/sc/source/ui/cctrl/checklistmenu.cxx b/sc/source/ui/cctrl/checklistmenu.cxx
index 7086a72f7fe2..6f369e9e280c 100644
--- a/sc/source/ui/cctrl/checklistmenu.cxx
+++ b/sc/source/ui/cctrl/checklistmenu.cxx
@@ -1714,8 +1714,11 @@ SvTreeListEntry* ScCheckListBox::ShowCheckEntry( const OUString& sName, ScCheckL
{
if ( !pEntry )
{
- if ( rMember.mbDate )
+ if (rMember.mbDate)
{
+ if (rMember.maDateParts.empty())
+ return nullptr;
+
SvTreeListEntry* pYearEntry = FindEntry( nullptr, rMember.maDateParts[0] );
if ( !pYearEntry )
pYearEntry = InsertEntry( rMember.maDateParts[0], nullptr, true );