diff options
author | Caolán McNamara <caolanm@redhat.com> | 2014-05-07 11:35:48 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2014-05-07 15:47:25 +0100 |
commit | d348f398830e523cc07d3047e978be12d6327114 (patch) | |
tree | 8824545ffe6e462ebd81a95a59687e8f75acdf34 /chart2 | |
parent | 439d6a07f7bc69dfa6184fd24bed499a804980f3 (diff) |
coverity#1209592 Unchecked dynamic_cast
Change-Id: Id9ac29ec88a98e626a1ecfb364e474b2a11a8004
Diffstat (limited to 'chart2')
-rw-r--r-- | chart2/source/view/main/OpenglShapeFactory.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/chart2/source/view/main/OpenglShapeFactory.cxx b/chart2/source/view/main/OpenglShapeFactory.cxx index 2ca81cad36cc..56beb5e163d9 100644 --- a/chart2/source/view/main/OpenglShapeFactory.cxx +++ b/chart2/source/view/main/OpenglShapeFactory.cxx @@ -154,7 +154,8 @@ uno::Reference< drawing::XShapes > OpenglShapeFactory::getOrCreateChartRootShape xPropSet->setPropertyValue( UNO_NAME_MISC_OBJ_NAME, aName ); SvxOpenGLObject* pObj = dynamic_cast<SvxOpenGLObject*>(xTarget.get()); - pObj->setRenderer(new OpenGLChartAdapter(xChart)); + if (pObj) + pObj->setRenderer(new OpenGLChartAdapter(xChart)); xRet = getChartShape( xDrawPage ); } |