Kaydet (Commit) c72f099d authored tarafından Caolán McNamara's avatar Caolán McNamara

coverity#1158102 Unchecked dynamic_cast

Change-Id: I806e1c4cd768aec0bb5d56449a1692226f20895e
üst 0d1d6aa2
...@@ -408,6 +408,7 @@ void SdFiltersTest::testFdo72998() ...@@ -408,6 +408,7 @@ void SdFiltersTest::testFdo72998()
CPPUNIT_ASSERT_MESSAGE( "no page", pPage != NULL ); CPPUNIT_ASSERT_MESSAGE( "no page", pPage != NULL );
{ {
SdrObjCustomShape *pObj = dynamic_cast<SdrObjCustomShape *>(pPage->GetObj(2)); SdrObjCustomShape *pObj = dynamic_cast<SdrObjCustomShape *>(pPage->GetObj(2));
CPPUNIT_ASSERT( pObj );
const SdrCustomShapeGeometryItem& rGeometryItem = (const SdrCustomShapeGeometryItem&)pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ); const SdrCustomShapeGeometryItem& rGeometryItem = (const SdrCustomShapeGeometryItem&)pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY );
CPPUNIT_ASSERT_MESSAGE( "not a custom shape", pObj ); CPPUNIT_ASSERT_MESSAGE( "not a custom shape", pObj );
const ::com::sun::star::uno::Any* pViewBox = ((SdrCustomShapeGeometryItem&)rGeometryItem).GetPropertyValueByName( OUString( "ViewBox" ) ); const ::com::sun::star::uno::Any* pViewBox = ((SdrCustomShapeGeometryItem&)rGeometryItem).GetPropertyValueByName( OUString( "ViewBox" ) );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment