diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2014-05-22 19:51:41 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2014-05-22 19:52:28 +0200 |
commit | c0765d1b5e317ec542be8285649c2c2a70892eff (patch) | |
tree | 404142313b19268d4dc658d57210066b2f975f8b /sw | |
parent | 8e2b894c30f90c577857a16bab13e45f867bf36e (diff) |
coverity#735895 Unchecked dynamic_cast
Change-Id: I6c2cc90668a2158a0b5bf638ce520c8af7731f4e
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/doc/docbm.cxx | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sw/source/core/doc/docbm.cxx b/sw/source/core/doc/docbm.cxx index 72764a60b440..6519285e15a3 100644 --- a/sw/source/core/doc/docbm.cxx +++ b/sw/source/core/doc/docbm.cxx @@ -417,6 +417,9 @@ namespace sw { namespace mark " - Mark was not created."); MarkBase* pMarkBase = dynamic_cast<MarkBase*>(pMark.get()); + if (!pMark) + return 0; + if(pMark->GetMarkPos() != pMark->GetMarkStart()) pMarkBase->Swap(); |