[Libreoffice-commits] core.git: sw/source
Caolán McNamara (via logerrit)
logerrit at kemper.freedesktop.org
Wed Dec 9 12:02:29 UTC 2020
sw/source/core/fields/usrfld.cxx | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit cc1bba7d3a683574b2c116ab5be99be81cce93af
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Wed Dec 9 09:36:40 2020 +0000
Commit: Caolán McNamara <caolanm at redhat.com>
CommitDate: Wed Dec 9 13:01:43 2020 +0100
cid#1470573 Unchecked dynamic_cast
Change-Id: I8489d82a293dc194dac183d3a117f4e256eb8043
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107457
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/sw/source/core/fields/usrfld.cxx b/sw/source/core/fields/usrfld.cxx
index 431a3ba0675f..0cff28fd7ba7 100644
--- a/sw/source/core/fields/usrfld.cxx
+++ b/sw/source/core/fields/usrfld.cxx
@@ -216,7 +216,7 @@ OUString SwUserFieldType::GetName() const
void SwUserFieldType::SwClientNotify(const SwModify&, const SfxHint& rHint)
{
auto pLegacy = dynamic_cast<const sw::LegacyModifyHint*>(&rHint);
- if(!pLegacy->m_pOld && !pLegacy->m_pNew)
+ if (pLegacy && !pLegacy->m_pOld && !pLegacy->m_pNew)
m_bValidValue = false;
CallSwClientNotify(rHint);
More information about the Libreoffice-commits
mailing list