diff options
author | Caolán McNamara <caolanm@redhat.com> | 2016-12-09 11:09:21 +0000 |
---|---|---|
committer | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2016-12-10 04:44:15 +0000 |
commit | 3e60ccb74ac6589e14a479c6646c63a4e5ac4e35 (patch) | |
tree | 6649bec976ce63e6bf0a63df43d0ca47a91861c5 | |
parent | 6715b5730e3373bcb55a4fba504d88b89f5ec917 (diff) |
Related: rhbz#1397939 crash with null pSidebarController
Change-Id: I7627ff30564b2de61669c71dafd15e7b1778b5c6
(cherry picked from commit f5edbb4158e86bfea7267115395b64e60fd61dc7)
(cherry picked from commit 5768416761756a386cba54314f783cb9c0d0d093)
Reviewed-on: https://gerrit.libreoffice.org/31787
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
-rw-r--r-- | sfx2/source/sidebar/Panel.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sfx2/source/sidebar/Panel.cxx b/sfx2/source/sidebar/Panel.cxx index 9c05ddedc352..d5c6b7852705 100644 --- a/sfx2/source/sidebar/Panel.cxx +++ b/sfx2/source/sidebar/Panel.cxx @@ -115,14 +115,14 @@ void Panel::SetUIElement (const Reference<ui::XUIElement>& rxElement) void Panel::SetExpanded (const bool bIsExpanded) { - SidebarController* pSidebarController= SidebarController::GetSidebarControllerForFrame(mxFrame); + SidebarController* pSidebarController = SidebarController::GetSidebarControllerForFrame(mxFrame); if (mbIsExpanded != bIsExpanded) { mbIsExpanded = bIsExpanded; maDeckLayoutTrigger(); - if (maContextAccess) + if (maContextAccess && pSidebarController) { pSidebarController->GetResourceManager()->StorePanelExpansionState( msPanelId, |