[Libreoffice-commits] core.git: svx/source
Szymon KÅos (via logerrit)
logerrit at kemper.freedesktop.org
Wed Jul 8 07:54:16 UTC 2020
svx/source/tbxctrls/StylesPreviewWindow.cxx | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
New commits:
commit 0695b5f5b328a1bc9cfdc8ba020dbdd674185e04
Author: Szymon Kłos <szymon.klos at collabora.com>
AuthorDate: Tue Jul 7 14:24:57 2020 +0200
Commit: Szymon Kłos <szymon.klos at collabora.com>
CommitDate: Wed Jul 8 09:53:39 2020 +0200
Avoid nullptr dereference
Change-Id: I5f2bd8206a1339e09f277cdc7f0c6a01a6d85df7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/98259
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
Reviewed-by: Szymon Kłos <szymon.klos at collabora.com>
(cherry picked from commit c9ceaeaee923a742d842fbc6174222eaf9667ca6)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/98270
Tested-by: Jenkins
diff --git a/svx/source/tbxctrls/StylesPreviewWindow.cxx b/svx/source/tbxctrls/StylesPreviewWindow.cxx
index 09e8a849fb68..7861467422d1 100644
--- a/svx/source/tbxctrls/StylesPreviewWindow.cxx
+++ b/svx/source/tbxctrls/StylesPreviewWindow.cxx
@@ -66,7 +66,8 @@ StyleStatusListener::StyleStatusListener(
void StyleStatusListener::StateChanged(SfxItemState /*eState*/, const SfxPoolItem* pState)
{
const SfxTemplateItem* pStateItem = dynamic_cast<const SfxTemplateItem*>(pState);
- m_pPreviewControl->Select(pStateItem->GetStyleName());
+ if (pStateItem)
+ m_pPreviewControl->Select(pStateItem->GetStyleName());
}
StyleItemController::StyleItemController(
More information about the Libreoffice-commits
mailing list