[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.4' - svx/source
Szymon KÅos (via logerrit)
logerrit at kemper.freedesktop.org
Tue Jul 7 12:58:12 UTC 2020
svx/source/tbxctrls/StylesPreviewWindow.cxx | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
New commits:
commit c9ceaeaee923a742d842fbc6174222eaf9667ca6
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: Tue Jul 7 14:57: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>
diff --git a/svx/source/tbxctrls/StylesPreviewWindow.cxx b/svx/source/tbxctrls/StylesPreviewWindow.cxx
index 01bd8037b0f7..4ff428a73e66 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