diff options
author | Caolán McNamara <caolanm@redhat.com> | 2014-05-24 11:54:48 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2014-05-24 13:03:46 +0100 |
commit | 8e304f80bbb7e2d6bab449d97bc6cb59d73069f3 (patch) | |
tree | 98a9b622c52e935a26ce7968bc8858a827ea412e /svx/source | |
parent | 10c14f13a7bc314ccff41c60c7e1d6fdaae19450 (diff) |
coverity#1027650 Unchecked dynamic_cast
Change-Id: Ic1973463e4c6d85bbfacc077f58f7d1fe16de73a
Diffstat (limited to 'svx/source')
-rw-r--r-- | svx/source/sidebar/insert/InsertPropertyPanel.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/svx/source/sidebar/insert/InsertPropertyPanel.cxx b/svx/source/sidebar/insert/InsertPropertyPanel.cxx index 7a8bf59f128f..9cc47bc87042 100644 --- a/svx/source/sidebar/insert/InsertPropertyPanel.cxx +++ b/svx/source/sidebar/insert/InsertPropertyPanel.cxx @@ -99,7 +99,8 @@ IMPL_LINK(InsertPropertyPanel, WindowEventListener, VclSimpleEvent*, pEvent) if (pEvent->GetId() != VCLEVENT_TOOLBOX_SELECT) return 1; - Window* pWindow = dynamic_cast<VclWindowEvent*>(pEvent)->GetWindow(); + VclWindowEvent* pWindowEvent = dynamic_cast<VclWindowEvent*>(pEvent); + Window* pWindow = pWindowEvent ? pWindowEvent->GetWindow() : NULL; ToolBox* pToolBox = dynamic_cast<ToolBox*>(pWindow); if (pToolBox == NULL) return 1; |