summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authorSzymon Kłos <szymon.klos@collabora.com>2021-03-24 11:45:51 +0100
committerSzymon Kłos <szymon.klos@collabora.com>2021-04-08 15:45:53 +0200
commit9e88172d28edf315676f52ed9a99077e95cd9628 (patch)
treed943d04790d4dedf901661badc1ccd4b8d945f68 /sfx2
parent3889d15537ad1cc3db9dce6f410dc42265d873b9 (diff)
SfxInPlaceClient: avoid crash when chart deleted by other view
Be sure m_pClient still is valid. In case when one view was in the chart editing mode and other view deleted the slide, m_pClient was cleared in the meantime what caused a crash Change-Id: Ie433946799abef4c75af7b96f3e5cf9ba0e7ec47 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113032 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Jan Holesovsky <kendy@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113786 Tested-by: Jenkins Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/source/view/ipclient.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/sfx2/source/view/ipclient.cxx b/sfx2/source/view/ipclient.cxx
index 1d3c375b6eb4..3c40c7bdf4a6 100644
--- a/sfx2/source/view/ipclient.cxx
+++ b/sfx2/source/view/ipclient.cxx
@@ -308,7 +308,8 @@ void SAL_CALL SfxInPlaceClient_Impl::visibilityChanged( sal_Bool bVisible )
throw uno::RuntimeException();
m_pClient->GetViewShell()->OutplaceActivated( bVisible );
- m_pClient->Invalidate();
+ if (m_pClient) // it can change in the above code
+ m_pClient->Invalidate();
}